Documentation ¶
Overview ¶
Package comet defines the Comet Service interface and BlockInfo types which applications should use in order to get access to the current block's evidence, validators hash, proposer address.
This information is specific to Comet
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BlockIDFlag ¶ added in v0.8.0
type BlockIDFlag int32
BlockIdFlag indicates which BlockID the signature is for
const ( BlockIDFlagUnknown BlockIDFlag = 0 // BlockIDFlagAbsent - no vote was received from a validator. BlockIDFlagAbsent BlockIDFlag = 1 // BlockIDFlagCommit - voted for the Commit.BlockID. BlockIDFlagCommit BlockIDFlag = 2 // BlockIDFlagNil - voted for nil. BlockIDFlagNil BlockIDFlag = 3 )
type CometInfoService ¶ added in v0.12.0
BlockInfoService is an interface that can be used to get information specific to Comet
type CommitInfo ¶
CommitInfo is the commit information of ABCI
type Evidence ¶
type Evidence struct { Type MisbehaviorType Validator Validator Height int64 Time time.Time TotalVotingPower int64 }
Evidence is the misbehavior information of ABCI
type Info ¶ added in v0.12.0
type Info struct { Evidence []Evidence // Evidence misbehavior of the block // ValidatorsHash returns the hash of the validators // For Comet, it is the hash of the next validator set ValidatorsHash []byte ProposerAddress []byte // ProposerAddress is the address of the block proposer LastCommit CommitInfo // DecidedLastCommit returns the last commit info }
Info is the information comet provides apps in ABCI
type MisbehaviorType ¶
type MisbehaviorType int32
MisbehaviorType is the type of misbehavior for a validator
const ( Unknown MisbehaviorType = 0 DuplicateVote MisbehaviorType = 1 LightClientAttack MisbehaviorType = 2 )
type Validator ¶
Validator is the validator information of ABCI
type VoteInfo ¶
type VoteInfo struct { Validator Validator BlockIDFlag BlockIDFlag }
VoteInfo is the vote information of ABCI