Class: Coradoc::Element::Attribute
- Defined in:
- lib/coradoc/element/attribute.rb
Instance Attribute Summary collapse
-
#key ⇒ Object
Returns the value of attribute key.
-
#value ⇒ Object
Returns the value of attribute value.
Instance Method Summary collapse
-
#initialize(key, value, _options = {}) ⇒ Attribute
constructor
A new instance of Attribute.
Methods inherited from Base
#children_accessors, children_accessors, declare_children, #simplify_block_content, visit, #visit
Constructor Details
#initialize(key, value, _options = {}) ⇒ Attribute
Returns a new instance of Attribute.
6 7 8 9 |
# File 'lib/coradoc/element/attribute.rb', line 6 def initialize(key, value, = {}) @key = key.to_s @value = build_values(value.to_s) end |
Instance Attribute Details
#key ⇒ Object
Returns the value of attribute key.
4 5 6 |
# File 'lib/coradoc/element/attribute.rb', line 4 def key @key end |
#value ⇒ Object
Returns the value of attribute value.
4 5 6 |
# File 'lib/coradoc/element/attribute.rb', line 4 def value @value end |