Method: Mongo::Protocol::Serializers::Byte.deserialize

Defined in:
lib/mongo/protocol/serializers.rb

.deserialize(buffer, options = {}) ⇒ String

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Deserializes a byte from the byte buffer.

Parameters:

  • buffer (BSON::ByteBuffer)

    Buffer containing the value to read.

  • options (Hash) (defaults to: {})

    This method currently accepts no options.

Returns:

  • (String)

    The byte.

Since:

  • 2.5.0



426
427
428
# File 'lib/mongo/protocol/serializers.rb', line 426

def self.deserialize(buffer, options = {})
  buffer.get_byte
end