Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Validator ¶
type Validator[V types.Hashable[H], H types.Hash, A types.Addr] interface { // ProposalInit initialises the pending state according to the proposal ProposalInit(pInit *types.ProposalInit) error // BlockInfo sets the pending header according to the proposal header BlockInfo(blockInfo *types.BlockInfo) // TransactionBatch executes the provided transactions, and stores the result in the pending state TransactionBatch(txn []types.Transaction) error // ProposalCommitment checks the set of proposed commitments against those generated locally. ProposalCommitment(proposalCommitment *types.ProposalCommitment) error // ProposalFin compares the provided commitment with that generated locally ProposalFin(proposalFin types.ProposalFin) error }
Validator is used to validate new proposals. There are two potential flows, and functions must be called in order: Flow 1) Non-empty proposal - ProposalInit(), BlockInfo(), TransactionBatch(), ProposalCommitment(), ProposalFin() Flow 2) Empty proposal - ProposalInit(), ProposalCommitment(), ProposalFin()
Click to show internal directories.
Click to hide internal directories.