Class: Protocol::WebSocket::BinaryFrame
- Defined in:
- lib/protocol/websocket/binary_frame.rb
Constant Summary collapse
- OPCODE =
0x2
Constants inherited from Frame
Frame::RESERVED, Frame::RSV1, Frame::RSV2, Frame::RSV3
Instance Attribute Summary
Attributes inherited from Frame
#finished, #flags, #length, #mask, #opcode, #payload
Instance Method Summary collapse
Methods inherited from Frame
#<=>, #continued?, #control?, #finished?, #initialize, #pack, parse_header, read, #to_ary, #unpack, #write
Constructor Details
This class inherits a constructor from Protocol::WebSocket::Frame
Instance Method Details
#apply(connection) ⇒ Object
23 24 25 |
# File 'lib/protocol/websocket/binary_frame.rb', line 23 def apply(connection) connection.receive_binary(self) end |
#data? ⇒ Boolean
15 16 17 |
# File 'lib/protocol/websocket/binary_frame.rb', line 15 def data? true end |
#read_message(buffer) ⇒ Object
19 20 21 |
# File 'lib/protocol/websocket/binary_frame.rb', line 19 def (buffer) return BinaryMessage.new(buffer) end |