Documentation ¶
Index ¶
- Constants
- func CheckLedger(chain Chain, genesisSnapshotBlock *ledger.SnapshotBlock) (byte, error)
- func InitLedger(chain Chain, genesisSnapshotBlock *ledger.SnapshotBlock, ...) error
- func NewGenesisAccountBlocks(cfg *config.Genesis) []*vm_db.VmAccountBlock
- func NewGenesisSnapshotBlock(accountBlocks []*vm_db.VmAccountBlock) *ledger.SnapshotBlock
- func VmBlocksToHashMap(accountBlocks []*vm_db.VmAccountBlock) map[types.Hash]struct{}
- type Chain
Constants ¶
Variables ¶
This section is empty.
Functions ¶
func CheckLedger ¶
func CheckLedger(chain Chain, genesisSnapshotBlock *ledger.SnapshotBlock) (byte, error)
func InitLedger ¶
func InitLedger(chain Chain, genesisSnapshotBlock *ledger.SnapshotBlock, vmBlocks []*vm_db.VmAccountBlock) error
func NewGenesisAccountBlocks ¶
func NewGenesisAccountBlocks(cfg *config.Genesis) []*vm_db.VmAccountBlock
func NewGenesisSnapshotBlock ¶
func NewGenesisSnapshotBlock(accountBlocks []*vm_db.VmAccountBlock) *ledger.SnapshotBlock
func VmBlocksToHashMap ¶
func VmBlocksToHashMap(accountBlocks []*vm_db.VmAccountBlock) map[types.Hash]struct{}
Types ¶
type Chain ¶
type Chain interface { InsertSnapshotBlock(snapshotBlock *ledger.SnapshotBlock) (invalidAccountBlocks []*ledger.AccountBlock, err error) InsertAccountBlock(vmAccountBlocks *vm_db.VmAccountBlock) error QuerySnapshotBlockByHeight(uint64) (*ledger.SnapshotBlock, error) GetContentNeedSnapshot() ledger.SnapshotContent }
Click to show internal directories.
Click to hide internal directories.