Module: Mongo::Protocol::Serializers::CString Private
Relationships & Source Files | |
Defined in: | lib/mongo/protocol/serializers.rb |
Overview
MongoDB wire protocol serialization strategy for C style strings.
Serializes and de-serializes C style strings (null terminated).
Class Method Summary
-
.serialize(buffer, value, validating_keys = nil) ⇒ String
Internal use only
Serializes a C style string into the buffer.
Class Method Details
.serialize(buffer, value, validating_keys = nil) ⇒ String
Serializes a C style string into the buffer
# File 'lib/mongo/protocol/serializers.rb', line 85
def self.serialize(buffer, value, validating_keys = nil) buffer.put_cstring(value) end