Interface for a Thrift protocol implementation. Essentially, it defines
a way of reading and writing all the base types, plus a mechanism for
writing out structs with indexed fields.
TProtocol objects should not be shared across multiple encoding contexts,
as they may need to maintain internal state in some protocols (e.g. JSON).
Note that is is acceptable for the TProtocol module to do its own internal
buffered reads/writes to the underlying TTransport where appropriate (i.e.
when parsing an input XML stream, reading could be batched rather than
looking ahead character by character for a close tag).
Interface for a Thrift protocol implementation. Essentially, it defines a way of reading and writing all the base types, plus a mechanism for writing out structs with indexed fields.
TProtocol objects should not be shared across multiple encoding contexts, as they may need to maintain internal state in some protocols (e.g. JSON). Note that is is acceptable for the TProtocol module to do its own internal buffered reads/writes to the underlying TTransport where appropriate (i.e. when parsing an input XML stream, reading could be batched rather than looking ahead character by character for a close tag).