Module: MIDIMessage::Constant
- Defined in:
- lib/midi-message/constant.rb
Overview
Refer to a MIDI message by its usage eg C4 for MIDI note 60 or *Bank Select* for MIDI control change 0
Defined Under Namespace
Modules: Loader, Name, Status Classes: Group, Map, MessageBuilder
Class Method Summary collapse
-
.find(group_name, const_name) ⇒ MIDIMessage::Constant::Map?
Get a Mapping object for the specified constant.
-
.value(group_name, const_name) ⇒ Object
Get the value of the specified constant.
Class Method Details
.find(group_name, const_name) ⇒ MIDIMessage::Constant::Map?
Get a Mapping object for the specified constant
11 12 13 14 |
# File 'lib/midi-message/constant.rb', line 11 def self.find(group_name, const_name) group = Group[group_name] group.find(const_name) end |
.value(group_name, const_name) ⇒ Object
Get the value of the specified constant
20 21 22 23 |
# File 'lib/midi-message/constant.rb', line 20 def self.value(group_name, const_name) map = find(group_name, const_name) map.value end |