Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CvpCodec ¶
type CvpCodec interface {
// EncodeStreamingLightValidators encodes the given light validators information into sorter string for streaming.
// Input is assumed to be valid, otherwise panic.
EncodeStreamingLightValidators(types.StreamingLightValidators) []byte
// DecodeStreamingLightValidators decodes the given string into light validators.
DecodeStreamingLightValidators([]byte) (types.StreamingLightValidators, error)
// EncodeStreamingNextBlockVotingInformation encodes the given next block voting information into sorter string for streaming.
// Input is assumed to be valid, otherwise panic.
EncodeStreamingNextBlockVotingInformation(*types.StreamingNextBlockVotingInformation) []byte
// DecodeStreamingNextBlockVotingInformation decodes the given string into next block voting information.
DecodeStreamingNextBlockVotingInformation([]byte) (*types.StreamingNextBlockVotingInformation, error)
}
CvpCodec is the interface for encoding and decoding streaming data.
func NewProxyCvpCodec ¶
func NewProxyCvpCodec() CvpCodec
NewProxyCvpCodec returns new instance of proxy CvpCodec.
The proxy automatically detect version of encoded data and forward to the corresponding implementation for decoding.
When invoking encode functions, it forward to default CvpCodec.
Click to show internal directories.
Click to hide internal directories.