Class: Clack::Core::SelectKeyOption
- Inherits:
-
Data
- Object
- Data
- Clack::Core::SelectKeyOption
- Defined in:
- lib/clack/core/options_helper.rb
Overview
Value object for select_key options (includes :key).
Instance Attribute Summary collapse
-
#hint ⇒ Object
readonly
Returns the value of attribute hint.
-
#key ⇒ Object
readonly
Returns the value of attribute key.
-
#label ⇒ Object
readonly
Returns the value of attribute label.
-
#value ⇒ Object
readonly
Returns the value of attribute value.
Instance Method Summary collapse
Instance Attribute Details
#hint ⇒ Object (readonly)
Returns the value of attribute hint
15 16 17 |
# File 'lib/clack/core/options_helper.rb', line 15 def hint @hint end |
#key ⇒ Object (readonly)
Returns the value of attribute key
15 16 17 |
# File 'lib/clack/core/options_helper.rb', line 15 def key @key end |
#label ⇒ Object (readonly)
Returns the value of attribute label
15 16 17 |
# File 'lib/clack/core/options_helper.rb', line 15 def label @label end |
#value ⇒ Object (readonly)
Returns the value of attribute value
15 16 17 |
# File 'lib/clack/core/options_helper.rb', line 15 def value @value end |
Instance Method Details
#[](key) ⇒ Object
17 |
# File 'lib/clack/core/options_helper.rb', line 17 def [](key) = to_h[key] |
#to_s ⇒ Object
16 |
# File 'lib/clack/core/options_helper.rb', line 16 def to_s = label.to_s |