Documentation ¶
Index ¶
- Variables
- type BlockBatch
- func (*BlockBatch) Descriptor() ([]byte, []int)
- func (m *BlockBatch) GetBatches() []*common.Block
- func (m *BlockBatch) Marshal() (dAtA []byte, err error)
- func (m *BlockBatch) MarshalTo(dAtA []byte) (int, error)
- func (m *BlockBatch) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*BlockBatch) ProtoMessage()
- func (m *BlockBatch) Reset()
- func (m *BlockBatch) Size() (n int)
- func (m *BlockBatch) String() string
- func (m *BlockBatch) Unmarshal(dAtA []byte) error
- func (m *BlockBatch) XXX_DiscardUnknown()
- func (m *BlockBatch) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *BlockBatch) XXX_Merge(src proto.Message)
- func (m *BlockBatch) XXX_Size() int
- func (m *BlockBatch) XXX_Unmarshal(b []byte) error
- type BlockHeightBCM
- func (*BlockHeightBCM) Descriptor() ([]byte, []int)
- func (m *BlockHeightBCM) GetArchivedHeight() uint64
- func (m *BlockHeightBCM) GetBlockHeight() uint64
- func (m *BlockHeightBCM) Marshal() (dAtA []byte, err error)
- func (m *BlockHeightBCM) MarshalTo(dAtA []byte) (int, error)
- func (m *BlockHeightBCM) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*BlockHeightBCM) ProtoMessage()
- func (m *BlockHeightBCM) Reset()
- func (m *BlockHeightBCM) Size() (n int)
- func (m *BlockHeightBCM) String() string
- func (m *BlockHeightBCM) Unmarshal(dAtA []byte) error
- func (m *BlockHeightBCM) XXX_DiscardUnknown()
- func (m *BlockHeightBCM) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *BlockHeightBCM) XXX_Merge(src proto.Message)
- func (m *BlockHeightBCM) XXX_Size() int
- func (m *BlockHeightBCM) XXX_Unmarshal(b []byte) error
- type BlockInfoBatch
- func (*BlockInfoBatch) Descriptor() ([]byte, []int)
- func (m *BlockInfoBatch) GetBatch() []*common.BlockInfo
- func (m *BlockInfoBatch) Marshal() (dAtA []byte, err error)
- func (m *BlockInfoBatch) MarshalTo(dAtA []byte) (int, error)
- func (m *BlockInfoBatch) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*BlockInfoBatch) ProtoMessage()
- func (m *BlockInfoBatch) Reset()
- func (m *BlockInfoBatch) Size() (n int)
- func (m *BlockInfoBatch) String() string
- func (m *BlockInfoBatch) Unmarshal(dAtA []byte) error
- func (m *BlockInfoBatch) XXX_DiscardUnknown()
- func (m *BlockInfoBatch) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *BlockInfoBatch) XXX_Merge(src proto.Message)
- func (m *BlockInfoBatch) XXX_Size() int
- func (m *BlockInfoBatch) XXX_Unmarshal(b []byte) error
- type BlockSyncRequest
- func (*BlockSyncRequest) Descriptor() ([]byte, []int)
- func (m *BlockSyncRequest) GetBatchSize() uint64
- func (m *BlockSyncRequest) GetBlockHeight() uint64
- func (m *BlockSyncRequest) GetWithRwset() bool
- func (m *BlockSyncRequest) Marshal() (dAtA []byte, err error)
- func (m *BlockSyncRequest) MarshalTo(dAtA []byte) (int, error)
- func (m *BlockSyncRequest) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*BlockSyncRequest) ProtoMessage()
- func (m *BlockSyncRequest) Reset()
- func (m *BlockSyncRequest) Size() (n int)
- func (m *BlockSyncRequest) String() string
- func (m *BlockSyncRequest) Unmarshal(dAtA []byte) error
- func (m *BlockSyncRequest) XXX_DiscardUnknown()
- func (m *BlockSyncRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *BlockSyncRequest) XXX_Merge(src proto.Message)
- func (m *BlockSyncRequest) XXX_Size() int
- func (m *BlockSyncRequest) XXX_Unmarshal(b []byte) error
- type SyncBlockBatch
- func (*SyncBlockBatch) Descriptor() ([]byte, []int)
- func (m *SyncBlockBatch) GetBlockBatch() *BlockBatch
- func (m *SyncBlockBatch) GetBlockinfoBatch() *BlockInfoBatch
- func (m *SyncBlockBatch) GetData() isSyncBlockBatch_Data
- func (m *SyncBlockBatch) GetWithRwset() bool
- func (m *SyncBlockBatch) Marshal() (dAtA []byte, err error)
- func (m *SyncBlockBatch) MarshalTo(dAtA []byte) (int, error)
- func (m *SyncBlockBatch) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*SyncBlockBatch) ProtoMessage()
- func (m *SyncBlockBatch) Reset()
- func (m *SyncBlockBatch) Size() (n int)
- func (m *SyncBlockBatch) String() string
- func (m *SyncBlockBatch) Unmarshal(dAtA []byte) error
- func (m *SyncBlockBatch) XXX_DiscardUnknown()
- func (m *SyncBlockBatch) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *SyncBlockBatch) XXX_Merge(src proto.Message)
- func (*SyncBlockBatch) XXX_OneofWrappers() []interface{}
- func (m *SyncBlockBatch) XXX_Size() int
- func (m *SyncBlockBatch) XXX_Unmarshal(b []byte) error
- type SyncBlockBatch_BlockBatch
- type SyncBlockBatch_BlockinfoBatch
- type SyncMessage
- func (*SyncMessage) Descriptor() ([]byte, []int)
- func (m *SyncMessage) GetPayoad() []byte
- func (m *SyncMessage) GetType() SyncMessage_MessageType
- func (m *SyncMessage) Marshal() (dAtA []byte, err error)
- func (m *SyncMessage) MarshalTo(dAtA []byte) (int, error)
- func (m *SyncMessage) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*SyncMessage) ProtoMessage()
- func (m *SyncMessage) Reset()
- func (m *SyncMessage) Size() (n int)
- func (m *SyncMessage) String() string
- func (m *SyncMessage) Unmarshal(dAtA []byte) error
- func (m *SyncMessage) XXX_DiscardUnknown()
- func (m *SyncMessage) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *SyncMessage) XXX_Merge(src proto.Message)
- func (m *SyncMessage) XXX_Size() int
- func (m *SyncMessage) XXX_Unmarshal(b []byte) error
- type SyncMessage_MessageType
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrInvalidLengthSync = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowSync = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupSync = fmt.Errorf("proto: unexpected end of group") )
View Source
var SyncMessage_MessageType_name = map[int32]string{
0: "NODE_STATUS_REQUEST",
1: "NODE_StATUS_RESPONSE",
2: "BLOCK_SYNC_REQUEST",
4: "BLOCK_SYNC_RESPONSE",
}
View Source
var SyncMessage_MessageType_value = map[string]int32{
"NODE_STATUS_REQUEST": 0,
"NODE_StATUS_RESPONSE": 1,
"BLOCK_SYNC_REQUEST": 2,
"BLOCK_SYNC_RESPONSE": 4,
}
Functions ¶
This section is empty.
Types ¶
type BlockBatch ¶
type BlockBatch struct {
Batches []*common.Block `protobuf:"bytes,1,rep,name=batches,proto3" json:"batches,omitempty"`
}
批处理块
func (*BlockBatch) Descriptor ¶
func (*BlockBatch) Descriptor() ([]byte, []int)
func (*BlockBatch) GetBatches ¶
func (m *BlockBatch) GetBatches() []*common.Block
func (*BlockBatch) Marshal ¶
func (m *BlockBatch) Marshal() (dAtA []byte, err error)
func (*BlockBatch) MarshalToSizedBuffer ¶
func (m *BlockBatch) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*BlockBatch) ProtoMessage ¶
func (*BlockBatch) ProtoMessage()
func (*BlockBatch) Reset ¶
func (m *BlockBatch) Reset()
func (*BlockBatch) Size ¶
func (m *BlockBatch) Size() (n int)
func (*BlockBatch) String ¶
func (m *BlockBatch) String() string
func (*BlockBatch) Unmarshal ¶
func (m *BlockBatch) Unmarshal(dAtA []byte) error
func (*BlockBatch) XXX_DiscardUnknown ¶
func (m *BlockBatch) XXX_DiscardUnknown()
func (*BlockBatch) XXX_Marshal ¶
func (m *BlockBatch) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*BlockBatch) XXX_Merge ¶
func (m *BlockBatch) XXX_Merge(src proto.Message)
func (*BlockBatch) XXX_Size ¶
func (m *BlockBatch) XXX_Size() int
func (*BlockBatch) XXX_Unmarshal ¶
func (m *BlockBatch) XXX_Unmarshal(b []byte) error
type BlockHeightBCM ¶
type BlockHeightBCM struct { BlockHeight uint64 `protobuf:"varint,1,opt,name=block_height,json=blockHeight,proto3" json:"block_height,omitempty"` ArchivedHeight uint64 `protobuf:"varint,2,opt,name=archived_height,json=archivedHeight,proto3" json:"archived_height,omitempty"` }
节点状态的响应消息
func (*BlockHeightBCM) Descriptor ¶
func (*BlockHeightBCM) Descriptor() ([]byte, []int)
func (*BlockHeightBCM) GetArchivedHeight ¶
func (m *BlockHeightBCM) GetArchivedHeight() uint64
func (*BlockHeightBCM) GetBlockHeight ¶
func (m *BlockHeightBCM) GetBlockHeight() uint64
func (*BlockHeightBCM) Marshal ¶
func (m *BlockHeightBCM) Marshal() (dAtA []byte, err error)
func (*BlockHeightBCM) MarshalToSizedBuffer ¶
func (m *BlockHeightBCM) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*BlockHeightBCM) ProtoMessage ¶
func (*BlockHeightBCM) ProtoMessage()
func (*BlockHeightBCM) Reset ¶
func (m *BlockHeightBCM) Reset()
func (*BlockHeightBCM) Size ¶
func (m *BlockHeightBCM) Size() (n int)
func (*BlockHeightBCM) String ¶
func (m *BlockHeightBCM) String() string
func (*BlockHeightBCM) Unmarshal ¶
func (m *BlockHeightBCM) Unmarshal(dAtA []byte) error
func (*BlockHeightBCM) XXX_DiscardUnknown ¶
func (m *BlockHeightBCM) XXX_DiscardUnknown()
func (*BlockHeightBCM) XXX_Marshal ¶
func (m *BlockHeightBCM) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*BlockHeightBCM) XXX_Merge ¶
func (m *BlockHeightBCM) XXX_Merge(src proto.Message)
func (*BlockHeightBCM) XXX_Size ¶
func (m *BlockHeightBCM) XXX_Size() int
func (*BlockHeightBCM) XXX_Unmarshal ¶
func (m *BlockHeightBCM) XXX_Unmarshal(b []byte) error
type BlockInfoBatch ¶
type BlockInfoBatch struct {
Batch []*common.BlockInfo `protobuf:"bytes,1,rep,name=batch,proto3" json:"batch,omitempty"`
}
批块信息
func (*BlockInfoBatch) Descriptor ¶
func (*BlockInfoBatch) Descriptor() ([]byte, []int)
func (*BlockInfoBatch) GetBatch ¶
func (m *BlockInfoBatch) GetBatch() []*common.BlockInfo
func (*BlockInfoBatch) Marshal ¶
func (m *BlockInfoBatch) Marshal() (dAtA []byte, err error)
func (*BlockInfoBatch) MarshalToSizedBuffer ¶
func (m *BlockInfoBatch) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*BlockInfoBatch) ProtoMessage ¶
func (*BlockInfoBatch) ProtoMessage()
func (*BlockInfoBatch) Reset ¶
func (m *BlockInfoBatch) Reset()
func (*BlockInfoBatch) Size ¶
func (m *BlockInfoBatch) Size() (n int)
func (*BlockInfoBatch) String ¶
func (m *BlockInfoBatch) String() string
func (*BlockInfoBatch) Unmarshal ¶
func (m *BlockInfoBatch) Unmarshal(dAtA []byte) error
func (*BlockInfoBatch) XXX_DiscardUnknown ¶
func (m *BlockInfoBatch) XXX_DiscardUnknown()
func (*BlockInfoBatch) XXX_Marshal ¶
func (m *BlockInfoBatch) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*BlockInfoBatch) XXX_Merge ¶
func (m *BlockInfoBatch) XXX_Merge(src proto.Message)
func (*BlockInfoBatch) XXX_Size ¶
func (m *BlockInfoBatch) XXX_Size() int
func (*BlockInfoBatch) XXX_Unmarshal ¶
func (m *BlockInfoBatch) XXX_Unmarshal(b []byte) error
type BlockSyncRequest ¶
type BlockSyncRequest struct { BlockHeight uint64 `protobuf:"varint,1,opt,name=block_height,json=blockHeight,proto3" json:"block_height,omitempty"` BatchSize uint64 `protobuf:"varint,2,opt,name=batch_size,json=batchSize,proto3" json:"batch_size,omitempty"` WithRwset bool `protobuf:"varint,3,opt,name=with_rwset,json=withRwset,proto3" json:"with_rwset,omitempty"` }
块请求消息
func (*BlockSyncRequest) Descriptor ¶
func (*BlockSyncRequest) Descriptor() ([]byte, []int)
func (*BlockSyncRequest) GetBatchSize ¶
func (m *BlockSyncRequest) GetBatchSize() uint64
func (*BlockSyncRequest) GetBlockHeight ¶
func (m *BlockSyncRequest) GetBlockHeight() uint64
func (*BlockSyncRequest) GetWithRwset ¶
func (m *BlockSyncRequest) GetWithRwset() bool
func (*BlockSyncRequest) Marshal ¶
func (m *BlockSyncRequest) Marshal() (dAtA []byte, err error)
func (*BlockSyncRequest) MarshalToSizedBuffer ¶
func (m *BlockSyncRequest) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*BlockSyncRequest) ProtoMessage ¶
func (*BlockSyncRequest) ProtoMessage()
func (*BlockSyncRequest) Reset ¶
func (m *BlockSyncRequest) Reset()
func (*BlockSyncRequest) Size ¶
func (m *BlockSyncRequest) Size() (n int)
func (*BlockSyncRequest) String ¶
func (m *BlockSyncRequest) String() string
func (*BlockSyncRequest) Unmarshal ¶
func (m *BlockSyncRequest) Unmarshal(dAtA []byte) error
func (*BlockSyncRequest) XXX_DiscardUnknown ¶
func (m *BlockSyncRequest) XXX_DiscardUnknown()
func (*BlockSyncRequest) XXX_Marshal ¶
func (m *BlockSyncRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*BlockSyncRequest) XXX_Merge ¶
func (m *BlockSyncRequest) XXX_Merge(src proto.Message)
func (*BlockSyncRequest) XXX_Size ¶
func (m *BlockSyncRequest) XXX_Size() int
func (*BlockSyncRequest) XXX_Unmarshal ¶
func (m *BlockSyncRequest) XXX_Unmarshal(b []byte) error
type SyncBlockBatch ¶
type SyncBlockBatch struct { // Types that are valid to be assigned to Data: // *SyncBlockBatch_BlockBatch // *SyncBlockBatch_BlockinfoBatch Data isSyncBlockBatch_Data `protobuf_oneof:"data"` WithRwset bool `protobuf:"varint,3,opt,name=with_rwset,json=withRwset,proto3" json:"with_rwset,omitempty"` }
块响应消息
func (*SyncBlockBatch) Descriptor ¶
func (*SyncBlockBatch) Descriptor() ([]byte, []int)
func (*SyncBlockBatch) GetBlockBatch ¶
func (m *SyncBlockBatch) GetBlockBatch() *BlockBatch
func (*SyncBlockBatch) GetBlockinfoBatch ¶
func (m *SyncBlockBatch) GetBlockinfoBatch() *BlockInfoBatch
func (*SyncBlockBatch) GetData ¶
func (m *SyncBlockBatch) GetData() isSyncBlockBatch_Data
func (*SyncBlockBatch) GetWithRwset ¶
func (m *SyncBlockBatch) GetWithRwset() bool
func (*SyncBlockBatch) Marshal ¶
func (m *SyncBlockBatch) Marshal() (dAtA []byte, err error)
func (*SyncBlockBatch) MarshalToSizedBuffer ¶
func (m *SyncBlockBatch) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*SyncBlockBatch) ProtoMessage ¶
func (*SyncBlockBatch) ProtoMessage()
func (*SyncBlockBatch) Reset ¶
func (m *SyncBlockBatch) Reset()
func (*SyncBlockBatch) Size ¶
func (m *SyncBlockBatch) Size() (n int)
func (*SyncBlockBatch) String ¶
func (m *SyncBlockBatch) String() string
func (*SyncBlockBatch) Unmarshal ¶
func (m *SyncBlockBatch) Unmarshal(dAtA []byte) error
func (*SyncBlockBatch) XXX_DiscardUnknown ¶
func (m *SyncBlockBatch) XXX_DiscardUnknown()
func (*SyncBlockBatch) XXX_Marshal ¶
func (m *SyncBlockBatch) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*SyncBlockBatch) XXX_Merge ¶
func (m *SyncBlockBatch) XXX_Merge(src proto.Message)
func (*SyncBlockBatch) XXX_OneofWrappers ¶
func (*SyncBlockBatch) XXX_OneofWrappers() []interface{}
XXX_OneofWrappers is for the internal use of the proto package.
func (*SyncBlockBatch) XXX_Size ¶
func (m *SyncBlockBatch) XXX_Size() int
func (*SyncBlockBatch) XXX_Unmarshal ¶
func (m *SyncBlockBatch) XXX_Unmarshal(b []byte) error
type SyncBlockBatch_BlockBatch ¶
type SyncBlockBatch_BlockBatch struct {
BlockBatch *BlockBatch `protobuf:"bytes,1,opt,name=block_batch,json=blockBatch,proto3,oneof" json:"block_batch,omitempty"`
}
func (*SyncBlockBatch_BlockBatch) MarshalTo ¶
func (m *SyncBlockBatch_BlockBatch) MarshalTo(dAtA []byte) (int, error)
func (*SyncBlockBatch_BlockBatch) MarshalToSizedBuffer ¶
func (m *SyncBlockBatch_BlockBatch) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*SyncBlockBatch_BlockBatch) Size ¶
func (m *SyncBlockBatch_BlockBatch) Size() (n int)
type SyncBlockBatch_BlockinfoBatch ¶
type SyncBlockBatch_BlockinfoBatch struct {
BlockinfoBatch *BlockInfoBatch `protobuf:"bytes,2,opt,name=blockinfo_batch,json=blockinfoBatch,proto3,oneof" json:"blockinfo_batch,omitempty"`
}
func (*SyncBlockBatch_BlockinfoBatch) MarshalTo ¶
func (m *SyncBlockBatch_BlockinfoBatch) MarshalTo(dAtA []byte) (int, error)
func (*SyncBlockBatch_BlockinfoBatch) MarshalToSizedBuffer ¶
func (m *SyncBlockBatch_BlockinfoBatch) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*SyncBlockBatch_BlockinfoBatch) Size ¶
func (m *SyncBlockBatch_BlockinfoBatch) Size() (n int)
type SyncMessage ¶
type SyncMessage struct { // 同步消息类型 Type SyncMessage_MessageType `protobuf:"varint,1,opt,name=type,proto3,enum=sync.SyncMessage_MessageType" json:"type,omitempty"` // 有效数据 Payoad []byte `protobuf:"bytes,2,opt,name=payoad,proto3" json:"payoad,omitempty"` }
同步模块的网络消息
func (*SyncMessage) Descriptor ¶
func (*SyncMessage) Descriptor() ([]byte, []int)
func (*SyncMessage) GetPayoad ¶
func (m *SyncMessage) GetPayoad() []byte
func (*SyncMessage) GetType ¶
func (m *SyncMessage) GetType() SyncMessage_MessageType
func (*SyncMessage) Marshal ¶
func (m *SyncMessage) Marshal() (dAtA []byte, err error)
func (*SyncMessage) MarshalToSizedBuffer ¶
func (m *SyncMessage) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*SyncMessage) ProtoMessage ¶
func (*SyncMessage) ProtoMessage()
func (*SyncMessage) Reset ¶
func (m *SyncMessage) Reset()
func (*SyncMessage) Size ¶
func (m *SyncMessage) Size() (n int)
func (*SyncMessage) String ¶
func (m *SyncMessage) String() string
func (*SyncMessage) Unmarshal ¶
func (m *SyncMessage) Unmarshal(dAtA []byte) error
func (*SyncMessage) XXX_DiscardUnknown ¶
func (m *SyncMessage) XXX_DiscardUnknown()
func (*SyncMessage) XXX_Marshal ¶
func (m *SyncMessage) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*SyncMessage) XXX_Merge ¶
func (m *SyncMessage) XXX_Merge(src proto.Message)
func (*SyncMessage) XXX_Size ¶
func (m *SyncMessage) XXX_Size() int
func (*SyncMessage) XXX_Unmarshal ¶
func (m *SyncMessage) XXX_Unmarshal(b []byte) error
type SyncMessage_MessageType ¶
type SyncMessage_MessageType int32
消息类型
const ( SyncMessage_NODE_STATUS_REQUEST SyncMessage_MessageType = 0 SyncMessage_NODE_StATUS_RESPONSE SyncMessage_MessageType = 1 SyncMessage_BLOCK_SYNC_REQUEST SyncMessage_MessageType = 2 SyncMessage_BLOCK_SYNC_RESPONSE SyncMessage_MessageType = 4 )
func (SyncMessage_MessageType) EnumDescriptor ¶
func (SyncMessage_MessageType) EnumDescriptor() ([]byte, []int)
func (SyncMessage_MessageType) String ¶
func (x SyncMessage_MessageType) String() string
Click to show internal directories.
Click to hide internal directories.