Documentation ¶
Index ¶
Constants ¶
View Source
const ( // consensus CodeBlockProposal = iota + 1 CodeBlockVote // protocol state sync CodeSyncRequest CodeSyncResponse CodeRangeRequest CodeBatchRequest CodeBlockResponse // cluster consensus CodeClusterBlockProposal CodeClusterBlockVote CodeClusterBlockResponse // collections, guarantees & transactions CodeCollectionGuarantee CodeTransaction CodeTransactionBody // core messages for execution & verification CodeExecutionReceipt CodeResultApproval // execution state synchronization CodeExecutionStateSyncRequest CodeExecutionStateDelta // data exchange for execution of blocks CodeChunkDataRequest CodeChunkDataResponse // generic entity exchange engines CodeEntityRequest CodeEntityResponse // testing CodeEcho )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Codec ¶
type Codec struct { }
Codec represents a JSON codec for our network.
func (*Codec) NewDecoder ¶
NewDecoder creates a new JSON decoder with the given underlying reader.
type Decoder ¶
type Decoder struct {
// contains filtered or unexported fields
}
Decoder implements a stream decoder for JSON.
type Encoder ¶
type Encoder struct {
// contains filtered or unexported fields
}
Encoder is an encoder to write serialized JSON to a writer.
type Envelope ¶
type Envelope struct { Code uint8 Data json.RawMessage }
Envelope is a wrapper to convey type information with JSON encoding without writing custom bytes to the wire.
Click to show internal directories.
Click to hide internal directories.