Class: MIDI::ChannelEvent

Inherits:
Event
  • Object
show all
Defined in:
lib/midilib/event.rb

Overview

The abstract superclass of all channel events (events that have a MIDI channel, like notes and program changes).

Instance Attribute Summary collapse

Attributes inherited from Event

#delta_time, #print_channel_numbers_from_one, #print_decimal_numbers, #print_note_names, #status, #time_from_start

Instance Method Summary collapse

Methods inherited from Event

#<=>, #channel_to_s, #data_as_bytes, #number_to_s, #quantize_to

Instance Attribute Details

#channelObject

MIDI channel, 0-15.



85
86
87
# File 'lib/midilib/event.rb', line 85

def channel
  @channel
end

Instance Method Details

#to_sObject



93
94
95
# File 'lib/midilib/event.rb', line 93

def to_s
  super << "ch #{channel_to_s(@channel)} "
end