class Thymeleaf::Template
Public Instance Methods
render()
click to toggle source
# File lib/thymeleaf/template.rb, line 9 def render do_render template_markup end
render_file()
click to toggle source
# File lib/thymeleaf/template.rb, line 13 def render_file template_markup_uri = Thymeleaf.configuration.template_uri(template_markup) template_file_open template_markup_uri do |template| do_render template end end
Private Instance Methods
do_render(template)
click to toggle source
# File lib/thymeleaf/template.rb, line 22 def do_render(template) parsed_template = Parser.new(template).call context_holder = ContextHolder.new(context) TemplateEngine.new.call(parsed_template, context_holder).to_s end
template_file_open(template_file) { |read| ... }
click to toggle source
# File lib/thymeleaf/template.rb, line 28 def template_file_open(template_file) File.open template_file do |template| template.rewind yield template.read end end