Class: MonomeSerial::SerialCommunicator::DummyCommunicator
- Inherits:
-
Communicator
- Object
- Communicator
- MonomeSerial::SerialCommunicator::DummyCommunicator
- Defined in:
- lib/monome_serial/serial_communicator/dummy_communicator.rb
Overview
Dummy class with no actual serial connection (so tests can execute in other Ruby environments)
Instance Method Summary collapse
-
#initialize ⇒ DummyCommunicator
constructor
A new instance of DummyCommunicator.
- #model ⇒ Object
- #read ⇒ Object
- #real? ⇒ Boolean
- #serial ⇒ Object
- #write(strings) ⇒ Object
Constructor Details
#initialize ⇒ DummyCommunicator
Returns a new instance of DummyCommunicator.
6 7 |
# File 'lib/monome_serial/serial_communicator/dummy_communicator.rb', line 6 def initialize end |
Instance Method Details
#model ⇒ Object
21 22 23 |
# File 'lib/monome_serial/serial_communicator/dummy_communicator.rb', line 21 def model "256" end |
#read ⇒ Object
9 10 11 12 |
# File 'lib/monome_serial/serial_communicator/dummy_communicator.rb', line 9 def read #super [:keydown, 1, 1] end |
#real? ⇒ Boolean
17 18 19 |
# File 'lib/monome_serial/serial_communicator/dummy_communicator.rb', line 17 def real? false end |
#serial ⇒ Object
25 26 27 |
# File 'lib/monome_serial/serial_communicator/dummy_communicator.rb', line 25 def serial "007" end |
#write(strings) ⇒ Object
14 15 |
# File 'lib/monome_serial/serial_communicator/dummy_communicator.rb', line 14 def write(strings) end |