Class: Solace::Serializers::TransactionDeserializer
- Inherits:
-
BaseDeserializer
- Object
- Base
- BaseDeserializer
- Solace::Serializers::TransactionDeserializer
- Defined in:
- lib/solace/serializers/transaction_deserializer.rb
Instance Attribute Summary
Attributes inherited from BaseDeserializer
Instance Method Summary collapse
-
#next_extract_message ⇒ Solace::Message
Extract the message from the transaction.
-
#next_extract_signatures ⇒ Array
Extract signatures from the transaction.
Methods inherited from BaseDeserializer
Methods inherited from Base
Constructor Details
This class inherits a constructor from Solace::Serializers::BaseDeserializer
Instance Method Details
#next_extract_message ⇒ Solace::Message
Extract the message from the transaction
The BufferLayout is:
- [Message (variable length)]
44 45 46 |
# File 'lib/solace/serializers/transaction_deserializer.rb', line 44 def record. = Solace::Serializers::MessageDeserializer.call(io) end |
#next_extract_signatures ⇒ Array
Extract signatures from the transaction
The BufferLayout is:
- [Number of signatures (compact u16)]
- [Signatures (variable length)]
33 34 35 36 |
# File 'lib/solace/serializers/transaction_deserializer.rb', line 33 def next_extract_signatures count, = Codecs.decode_compact_u16(io) record.signatures = count.times.map { io.read(64) } end |