Class: MusaLCEServer::Bitwig::Channel
- Inherits:
-
Object
- Object
- MusaLCEServer::Bitwig::Channel
- Defined in:
- lib/bitwig/controllers.rb
Instance Attribute Summary collapse
-
#channel_number ⇒ Object
readonly
Returns the value of attribute channel_number.
-
#name ⇒ Object
Returns the value of attribute name.
Instance Method Summary collapse
-
#initialize(controller, tracks, channel_number, logger:) ⇒ Channel
constructor
A new instance of Channel.
- #output ⇒ Object
- #to_s ⇒ Object
Constructor Details
#initialize(controller, tracks, channel_number, logger:) ⇒ Channel
Returns a new instance of Channel.
104 105 106 107 108 109 |
# File 'lib/bitwig/controllers.rb', line 104 def initialize(controller, tracks, channel_number, logger:) @controller = controller @tracks = tracks @channel_number = channel_number @logger = logger end |
Instance Attribute Details
#channel_number ⇒ Object (readonly)
Returns the value of attribute channel_number.
111 112 113 |
# File 'lib/bitwig/controllers.rb', line 111 def channel_number @channel_number end |
#name ⇒ Object
Returns the value of attribute name.
111 112 113 |
# File 'lib/bitwig/controllers.rb', line 111 def name @name end |
Instance Method Details
#output ⇒ Object
120 121 122 |
# File 'lib/bitwig/controllers.rb', line 120 def output @controller.midi_device.channels[@channel_number] end |
#to_s ⇒ Object
124 125 126 |
# File 'lib/bitwig/controllers.rb', line 124 def to_s "<Channel #{@channel_number} '#{@name}' on port '#{@controller.port_name}' (controller '#{@controller.name}')>" end |