class Node
Represents an immutable node within the content hierarchy.
Nested
Definitions
def lookup_tag(tag)
Lookup the given tag which is being rendered within the given node. Invoked by class Utopia::Content::Document.
Implementation
def lookup_tag(tag)
return @controller.lookup_tag(tag.name, self)
end
def call(document, state)
Invoked when the node is being rendered by class Utopia::Content::Document.
Implementation
def call(document, state)
# Load the template:
template = @controller.fetch_template(@file_path)
# Evaluate the template/code:
context = Context.new(document, state)
markup = template.to_buffer(context)
# Render the resulting markup into the document:
document.parse_markup(markup)
end