Class: Mysql::Protocol::FetchPacket
- Defined in:
- lib/mysql/protocol.rb
Overview
Fetch packet
Instance Attribute Summary collapse
-
#fetch_length ⇒ Object
Returns the value of attribute fetch_length.
-
#statement_id ⇒ Object
Returns the value of attribute statement_id.
Instance Method Summary collapse
-
#initialize(*args) ⇒ FetchPacket
constructor
A new instance of FetchPacket.
- #serialize ⇒ Object
Constructor Details
#initialize(*args) ⇒ FetchPacket
Returns a new instance of FetchPacket.
516 517 518 |
# File 'lib/mysql/protocol.rb', line 516 def initialize(*args) @statement_id, @fetch_length = args end |
Instance Attribute Details
#fetch_length ⇒ Object
Returns the value of attribute fetch_length.
514 515 516 |
# File 'lib/mysql/protocol.rb', line 514 def fetch_length @fetch_length end |
#statement_id ⇒ Object
Returns the value of attribute statement_id.
514 515 516 |
# File 'lib/mysql/protocol.rb', line 514 def statement_id @statement_id end |
Instance Method Details
#serialize ⇒ Object
520 521 522 |
# File 'lib/mysql/protocol.rb', line 520 def serialize [Mysql::COM_STMT_FETCH, statement_id, fetch_length].pack("CVV") end |