Class: Babl::Rendering::CompiledTemplate
- Inherits:
-
Object
- Object
- Babl::Rendering::CompiledTemplate
- Defined in:
- lib/babl/rendering/compiled_template.rb
Instance Attribute Summary collapse
-
#dependencies ⇒ Object
readonly
Returns the value of attribute dependencies.
-
#documentation ⇒ Object
readonly
Returns the value of attribute documentation.
-
#node ⇒ Object
readonly
Returns the value of attribute node.
-
#preloader ⇒ Object
readonly
Returns the value of attribute preloader.
-
#pretty ⇒ Object
readonly
Returns the value of attribute pretty.
Instance Method Summary collapse
-
#initialize(node, preloader: NoopPreloader, pretty: true) ⇒ CompiledTemplate
constructor
A new instance of CompiledTemplate.
- #json(root) ⇒ Object
- #render(root) ⇒ Object
Constructor Details
#initialize(node, preloader: NoopPreloader, pretty: true) ⇒ CompiledTemplate
Returns a new instance of CompiledTemplate.
8 9 10 11 12 13 14 |
# File 'lib/babl/rendering/compiled_template.rb', line 8 def initialize(node, preloader: NoopPreloader, pretty: true) @node = node @dependencies = node.dependencies @documentation = node.documentation @preloader = preloader @pretty = pretty end |
Instance Attribute Details
#dependencies ⇒ Object (readonly)
Returns the value of attribute dependencies.
6 7 8 |
# File 'lib/babl/rendering/compiled_template.rb', line 6 def dependencies @dependencies end |
#documentation ⇒ Object (readonly)
Returns the value of attribute documentation.
6 7 8 |
# File 'lib/babl/rendering/compiled_template.rb', line 6 def documentation @documentation end |
#node ⇒ Object (readonly)
Returns the value of attribute node.
6 7 8 |
# File 'lib/babl/rendering/compiled_template.rb', line 6 def node @node end |
#preloader ⇒ Object (readonly)
Returns the value of attribute preloader.
6 7 8 |
# File 'lib/babl/rendering/compiled_template.rb', line 6 def preloader @preloader end |
#pretty ⇒ Object (readonly)
Returns the value of attribute pretty.
6 7 8 |
# File 'lib/babl/rendering/compiled_template.rb', line 6 def pretty @pretty end |