Class: AmsLayout::Parser::Control
- Inherits:
-
Object
- Object
- AmsLayout::Parser::Control
- Defined in:
- lib/ams_layout/parser.rb
Instance Attribute Summary collapse
-
#id ⇒ Object
readonly
Returns the value of attribute id.
-
#label ⇒ Object
readonly
Returns the value of attribute label.
-
#type ⇒ Object
readonly
Returns the value of attribute type.
Instance Method Summary collapse
-
#initialize(label, id, type) ⇒ Control
constructor
A new instance of Control.
- #to_hash ⇒ Object
Constructor Details
#initialize(label, id, type) ⇒ Control
Returns a new instance of Control.
111 112 113 114 115 |
# File 'lib/ams_layout/parser.rb', line 111 def initialize label, id, type @label = label @id = id @type = type end |
Instance Attribute Details
#id ⇒ Object (readonly)
Returns the value of attribute id.
109 110 111 |
# File 'lib/ams_layout/parser.rb', line 109 def id @id end |
#label ⇒ Object (readonly)
Returns the value of attribute label.
109 110 111 |
# File 'lib/ams_layout/parser.rb', line 109 def label @label end |
#type ⇒ Object (readonly)
Returns the value of attribute type.
109 110 111 |
# File 'lib/ams_layout/parser.rb', line 109 def type @type end |
Instance Method Details
#to_hash ⇒ Object
117 118 119 |
# File 'lib/ams_layout/parser.rb', line 117 def to_hash {label: @label, id: @id, type: @type} end |