Documentation ¶
Index ¶
- func ConstructBlocksSyncMessage(blocks []*types.Block) []byte
- func ConstructCXReceiptsProof(cxReceiptsProof *types.CXReceiptsProof) []byte
- func ConstructCrossLinkHeartBeatMessage(hb types.CrosslinkHeartbeat) []byte
- func ConstructCrossLinkMessage(bc engine.ChainReader, headers []*block.Header) []byte
- func ConstructSlashMessage(witnesses slash.Records) []byte
- func ConstructStakingTransactionListMessageAccount(transactions staking.StakingTransactions) []byte
- func ConstructTransactionListMessageAccount(transactions types.Transactions) []byte
- type BlockMessageType
- type MessageType
- type TransactionMessageType
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ConstructBlocksSyncMessage ¶
ConstructBlocksSyncMessage constructs blocks sync message to send blocks to other nodes
func ConstructCXReceiptsProof ¶
func ConstructCXReceiptsProof(cxReceiptsProof *types.CXReceiptsProof) []byte
ConstructCXReceiptsProof constructs cross shard receipts and related proof including merkle proof, blockHeader and commitSignatures
func ConstructCrossLinkHeartBeatMessage ¶
func ConstructCrossLinkHeartBeatMessage(hb types.CrosslinkHeartbeat) []byte
func ConstructCrossLinkMessage ¶
func ConstructCrossLinkMessage(bc engine.ChainReader, headers []*block.Header) []byte
ConstructCrossLinkMessage constructs cross link message to send to beacon chain
func ConstructSlashMessage ¶
ConstructSlashMessage ..
func ConstructStakingTransactionListMessageAccount ¶
func ConstructStakingTransactionListMessageAccount( transactions staking.StakingTransactions, ) []byte
ConstructStakingTransactionListMessageAccount constructs serialized staking transactions in account model
func ConstructTransactionListMessageAccount ¶
func ConstructTransactionListMessageAccount(transactions types.Transactions) []byte
ConstructTransactionListMessageAccount constructs serialized transactions in account model
Types ¶
type BlockMessageType ¶
type BlockMessageType int
BlockMessageType represents the type of messages used for Node/Block
const ( Sync BlockMessageType = iota CrossLink // used for crosslink from beacon chain to shard chain Receipt // cross-shard transaction receipts SlashCandidate // A report of a double-signing event CrosslinkHeartbeat // Heart beat signal for crosslinks. Needed for epoch chain. )
Block sync message subtype
type MessageType ¶
type MessageType byte
MessageType is to indicate the specific type of message under Node category
const ( Transaction MessageType = iota Block Client PING // node send ip/pki to register with leader ShardState // Deprecated Staking )
Constant of the top level Message Type exchanged among nodes
type TransactionMessageType ¶
type TransactionMessageType int
TransactionMessageType representa the types of messages used for Node/Transaction
const ( Send TransactionMessageType = iota Unlock )
Constant of transaction message subtype