MCPcopy Create free account
hub / github.com/segmentio/encoding / Protocol

Interface Protocol

thrift/protocol.go:27–31  ·  view source on GitHub ↗

The Protocol interface abstracts the creation of low-level thrift readers and writers implementing the various protocols that the encoding supports. Protocol instances must be safe to use concurrently from multiple gourintes. However, the readers and writer that they instantiates are intended to be

Source from the content-addressed store, hash-verified

25// However, the readers and writer that they instantiates are intended to be
26// used by a single goroutine.
27type Protocol interface {
28 NewReader(r io.Reader) Reader
29 NewWriter(w io.Writer) Writer
30 Features() Features
31}
32
33// Reader represents a low-level reader of values encoded according to one of
34// the thrift protocols.

Callers 13

TestDecodeEOFFunction · 0.65
benchmarkUnmarshalFunction · 0.65
UnmarshalFunction · 0.65
codeInitFunction · 0.65
BenchmarkUnicodeDecoderFunction · 0.65
ExampleDecoderFunction · 0.65
ExampleDecoder_TokenFunction · 0.65
benchmarkMarshalFunction · 0.65
MarshalFunction · 0.65
encoderFlagsFunction · 0.65

Implementers 2

BinaryProtocolthrift/binary.go
CompactProtocolthrift/compact.go

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…