Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type PoB ¶
type PoB struct {
// contains filtered or unexported fields
}
PoB is a struct that handles the consensus logic.
func New ¶ added in v1.1.0
func New(account *account.KeyPair, baseVariable global.BaseVariable, blockCache blockcache.BlockCache, txPool txpool.TxPool, p2pService p2p.Service) *PoB
New init a new PoB.
func (*PoB) RecoverBlock ¶ added in v1.1.0
func (p *PoB) RecoverBlock(blk *block.Block, witnessList blockcache.WitnessList) error
RecoverBlock recover block from block cache wal
type StaticProperty ¶
type StaticProperty struct { NumberOfWitnesses int64 WitnessList []string Watermark map[string]int64 SlotUsed map[int64]bool // contains filtered or unexported fields }
StaticProperty handles the the static property of pob.
func GetStaticProperty ¶ added in v1.1.0
func GetStaticProperty() *StaticProperty
GetStaticProperty return property. RPC needs it.
Click to show internal directories.
Click to hide internal directories.