Class: PlayToneReply
- Inherits:
-
DirectCommandReply
- Object
- Telegram
- Reply
- DirectCommandReply
- PlayToneReply
- Defined in:
- lib/telegrams/commands/direct/replies/play_tone_reply.rb
Constant Summary
Constants inherited from Reply
Reply::COMMAND_TYPE, Reply::STATUS_MESSAGES, Reply::SUCCESS
Instance Attribute Summary
Attributes inherited from Reply
#command, #message_bytes, #status, #status_description, #type
Attributes inherited from Telegram
Instance Method Summary collapse
-
#initialize(bytes) ⇒ PlayToneReply
constructor
A new instance of PlayToneReply.
- #validate_bytes(bytes) ⇒ Object
Methods inherited from Reply
Methods inherited from Telegram
Constructor Details
#initialize(bytes) ⇒ PlayToneReply
Returns a new instance of PlayToneReply.
4 5 6 |
# File 'lib/telegrams/commands/direct/replies/play_tone_reply.rb', line 4 def initialize(bytes) super(bytes) end |
Instance Method Details
#validate_bytes(bytes) ⇒ Object
9 10 11 12 |
# File 'lib/telegrams/commands/direct/replies/play_tone_reply.rb', line 9 def validate_bytes(bytes) super(bytes) raise ArgumentError, "must be a reply for the PlayTone command" unless bytes[1] == 0x03 end |