Class: ODT2HTML::Declaration
- Inherits:
-
Object
- Object
- ODT2HTML::Declaration
- Defined in:
- lib/odt2html-nsi/declaration.rb
Overview
This class represents a CSS declaration; a property/value pair
Instance Attribute Summary collapse
-
#property ⇒ Object
Returns the value of attribute property.
-
#value ⇒ Object
Returns the value of attribute value.
Instance Method Summary collapse
-
#initialize(property = nil, value = nil) ⇒ Declaration
constructor
A new instance of Declaration.
- #to_s ⇒ Object
Constructor Details
#initialize(property = nil, value = nil) ⇒ Declaration
Returns a new instance of Declaration.
6 7 8 9 |
# File 'lib/odt2html-nsi/declaration.rb', line 6 def initialize( property=nil, value=nil ) @property = property @value = value end |
Instance Attribute Details
#property ⇒ Object
Returns the value of attribute property.
5 6 7 |
# File 'lib/odt2html-nsi/declaration.rb', line 5 def property @property end |
#value ⇒ Object
Returns the value of attribute value.
5 6 7 |
# File 'lib/odt2html-nsi/declaration.rb', line 5 def value @value end |
Instance Method Details
#to_s ⇒ Object
11 12 13 |
# File 'lib/odt2html-nsi/declaration.rb', line 11 def to_s return "#{property}: #{value}" end |