Class: BlockHTML::Text
Direct Known Subclasses
Instance Attribute Summary
Attributes inherited from BlockHTML
Instance Method Summary collapse
-
#initialize(text) ⇒ Text
constructor
A new instance of Text.
- #render(renderer) ⇒ Object
Methods inherited from BlockHTML
#<<, #_p, #doctype, #each, #empty?, #escaped_text, #form, #method_missing, #p, #path, #root, #tag, #text, #to_s, #xml
Constructor Details
#initialize(text) ⇒ Text
Returns a new instance of Text.
155 156 157 158 |
# File 'lib/block-html.rb', line 155 def initialize(text) super() @text = text end |
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class BlockHTML
Instance Method Details
#render(renderer) ⇒ Object
160 161 162 |
# File 'lib/block-html.rb', line 160 def render(renderer) renderer.text(@text) end |