Class: HtmlSlicer::Processor
- Inherits:
-
Object
- Object
- HtmlSlicer::Processor
- Defined in:
- lib/html_slicer/processor.rb
Instance Attribute Summary collapse
-
#content ⇒ Object
Returns the value of attribute content.
Instance Method Summary collapse
- #export ⇒ Object
-
#initialize(stuff = nil) ⇒ Processor
constructor
A new instance of Processor.
- #make ⇒ Object
Constructor Details
#initialize(stuff = nil) ⇒ Processor
Returns a new instance of Processor.
6 7 8 9 10 11 12 13 14 15 16 |
# File 'lib/html_slicer/processor.rb', line 6 def initialize(stuff = nil) @content = case stuff when String then stuff else if stuff.respond_to?(:to_s) stuff.to_s else raise(TypeError, "String or responsible :to_s object expected, #{stuff.class} passed.") end end end |
Instance Attribute Details
#content ⇒ Object
Returns the value of attribute content.
4 5 6 |
# File 'lib/html_slicer/processor.rb', line 4 def content @content end |
Instance Method Details
#export ⇒ Object
21 22 23 |
# File 'lib/html_slicer/processor.rb', line 21 def export make end |
#make ⇒ Object
18 19 |
# File 'lib/html_slicer/processor.rb', line 18 def make end |