Skip to content

Latest commit

 

History

History
155 lines (81 loc) · 3.25 KB

CasperConsensus.md

File metadata and controls

155 lines (81 loc) · 3.25 KB

@ethereumjs/blockchain / CasperConsensus

Class: CasperConsensus

This class encapsulates Casper-related consensus functionality when used with the Blockchain class.

Implements

Table of contents

Constructors

Properties

Methods

Constructors

constructor

new CasperConsensus()

Defined in

consensus/casper.ts:12

Properties

algorithm

algorithm: ConsensusAlgorithm

Implementation of

Consensus.algorithm

Defined in

consensus/casper.ts:10

Methods

genesisInit

genesisInit(): Promise<void>

Initialize genesis for consensus mechanism

Returns

Promise<void>

Implementation of

Consensus.genesisInit

Defined in

consensus/casper.ts:16


newBlock

newBlock(): Promise<void>

Update consensus on new block

Returns

Promise<void>

Implementation of

Consensus.newBlock

Defined in

consensus/casper.ts:28


setup

setup(): Promise<void>

Set up consensus mechanism

Returns

Promise<void>

Implementation of

Consensus.setup

Defined in

consensus/casper.ts:18


validateConsensus

validateConsensus(): Promise<void>

Validate block consensus parameters

Returns

Promise<void>

Implementation of

Consensus.validateConsensus

Defined in

consensus/casper.ts:20


validateDifficulty

validateDifficulty(header): Promise<void>

Parameters

Name Type
header BlockHeader

Returns

Promise<void>

Implementation of

Consensus.validateDifficulty

Defined in

consensus/casper.ts:22