Class: MIDIMessage::Constant
- Inherits:
-
Object
- Object
- MIDIMessage::Constant
- Defined in:
- lib/midi-message/constant.rb
Instance Attribute Summary collapse
-
#key ⇒ Object
readonly
Returns the value of attribute key.
-
#value ⇒ Object
readonly
Returns the value of attribute value.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(key, value) ⇒ Constant
constructor
A new instance of Constant.
Constructor Details
#initialize(key, value) ⇒ Constant
Returns a new instance of Constant.
49 50 51 52 |
# File 'lib/midi-message/constant.rb', line 49 def initialize(key, value) @key = key @value = value end |
Instance Attribute Details
#key ⇒ Object (readonly)
Returns the value of attribute key.
47 48 49 |
# File 'lib/midi-message/constant.rb', line 47 def key @key end |
#value ⇒ Object (readonly)
Returns the value of attribute value.
47 48 49 |
# File 'lib/midi-message/constant.rb', line 47 def value @value end |
Class Method Details
.find(group_name, const_name) ⇒ Object
54 55 56 57 |
# File 'lib/midi-message/constant.rb', line 54 def self.find(group_name, const_name) group = ConstantGroup[group_name] group.find(const_name) end |