module Mattock::TemplateHost
@deprecated Use {Valise::Set#templates} instead
Attributes
valise[RW]
Public Instance Methods
find_template(path)
click to toggle source
XXX Better to let clients stem or subset
# File lib/mattock/template-host.rb, line 26 def find_template(path) valise.find(path) end
render(path) { |locals| ... }
click to toggle source
# File lib/mattock/template-host.rb, line 38 def render(path) locals = {} if block_given? yield locals end template(path).render(self, locals) end
template(path)
click to toggle source
# File lib/mattock/template-host.rb, line 30 def template(path) find_template(path).contents end
template_path(path)
click to toggle source
# File lib/mattock/template-host.rb, line 34 def template_path(path) find_template(path).full_path end
templates_are_in(valise)
click to toggle source
# File lib/mattock/template-host.rb, line 21 def templates_are_in(valise) self.valise = valise.templates end