Malt  Malt::Format::Tenjin

[Validate]
Generated with RDazzle Newfish 1.4.0

Tenjin

Tenjin

  http://www.kuwata-lab.com/tenjin/

Public Instance Methods

html(data=nil, &yld) click to toggle source
    # File lib/malt/formats/tenjin.rb, line 28
28:     def html(data=nil, &yld)
29:       render(:html, data, &yld)
30:     end
rb(*) click to toggle source
    # File lib/malt/formats/tenjin.rb, line 15
15:     def rb(*)
16:       render_engine.compile(text, file)
17:     end
to_html(data=nil, &yld) click to toggle source
    # File lib/malt/formats/tenjin.rb, line 33
33:     def to_html(data=nil, &yld)
34:       new_text    = render(:html, data, &yld)
35:       new_file    = refile(:html)
36:       new_options = options.merge(:text=>new_text, :file=>new_file, :type=>:html)
37:       HTML.new(new_options)
38:     end
to_rb(*) click to toggle source

Erb templates can be “precompiled” into Ruby templates.

    # File lib/malt/formats/tenjin.rb, line 20
20:     def to_rb(*)
21:       text = rb
22:       Ruby.new(:text=>text, :file=>refile(:rb), :type=>:rb)
23:     end
Also aliased as: to_ruby
to_ruby(*) click to toggle source

Private Instance Methods

render_engine() click to toggle source
    # File lib/malt/formats/tenjin.rb, line 43
43:     def render_engine
44:       @render_engine ||= Malt::Engine::Tenjin.new(options)
45:     end

Disabled; run with --debug to generate this.