Class: N::XhtmlBuilder
- Includes:
- XhtmlBuilderMixin, XmlBuilderMixin
- Defined in:
- lib/nitro/builders/xhtml.rb
Overview
A class that encapsulats the XHTML generation functionality. Utilizes duck typing to redirect output to a target buffer.
Instance Attribute Summary collapse
-
#target ⇒ Object
The target receives the generated xml, should respond_to :<<.
Instance Method Summary collapse
- #<<(str) ⇒ Object
-
#initialize(target = '') ⇒ XhtmlBuilder
constructor
A new instance of XhtmlBuilder.
- #to_s ⇒ Object
Methods included from XhtmlBuilderMixin
Methods included from XmlBuilderMixin
#comment, #end_tag, #method_missing, #start_tag, #text
Constructor Details
#initialize(target = '') ⇒ XhtmlBuilder
Returns a new instance of XhtmlBuilder.
100 101 102 |
# File 'lib/nitro/builders/xhtml.rb', line 100 def initialize(target = '') @target = target end |
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class N::XmlBuilderMixin
Instance Attribute Details
#target ⇒ Object
The target receives the generated xml, should respond_to :<<
98 99 100 |
# File 'lib/nitro/builders/xhtml.rb', line 98 def target @target end |