Module: MIDIEvents::Constant
- Defined in:
- lib/midi-events/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) ⇒ MIDIEvents::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) ⇒ MIDIEvents::Constant::Map?
Get a Mapping object for the specified constant
9 10 11 12 |
# File 'lib/midi-events/constant.rb', line 9 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
18 19 20 21 |
# File 'lib/midi-events/constant.rb', line 18 def self.value(group_name, const_name) map = find(group_name, const_name) map.value end |