# Functions
AccumulateRewards credits the coinbase of the given block with the mining reward.
ApplyDAOHardFork modifies the state database according to the DAO hard-fork rules, transferring all balances of a set of DAO accounts to a single refund contract.
ApplyMessage computes the new state by applying the given message against the old state within the environment.
ApplyTransaction attempts to apply a transaction to the given state database and uses the input parameters for its environment.
CalcDifficulty is the difficulty adjustment algorithm.
CalcGasLimit computes the gas limit of the next block after parent.
CanTransfer checks wether there are enough funds in the address' account to make a transfer.
DefaultGenesisBlock assembles a JSON string representing the default Ethereum genesis block.
No description provided by the author
DeleteBlock removes all block data associated with a hash.
DeleteBlockReceipts removes all receipt data associated with a block hash.
DeleteBody removes all block body data associated with a hash.
DeleteCanonicalHash removes the number to hash canonical mapping.
DeleteHeader removes all block header data associated with a hash.
DeleteReceipt removes all receipt data associated with a transaction hash.
DeleteTd removes all block total difficulty data associated with a hash.
DeleteTransaction removes all transaction data associated with a hash.
No description provided by the author
FindCommonAncestor returns the last common ancestor of two block headers.
GenerateChain creates a chain of n blocks.
GenesisBlockForTesting creates a block in which addr has the given wei balance.
GetBlock retrieves an entire block corresponding to the hash, assembling it back from the stored header and body.
[deprecated by the header/block split, remove eventually] GetBlockByHashOld returns the old combined block corresponding to the hash or nil if not found.
GetBlockChainVersion reads the version number from db.
GetBlockNumber returns the block number assigned to a block hash if the corresponding header is present in the database.
GetBlockReceipts retrieves the receipts generated by the transactions included in a block given by its hash.
GetBody retrieves the block body (transactons, uncles) corresponding to the hash, nil if none found.
GetBodyRLP retrieves the block body (transactions and uncles) in RLP encoding.
GetCanonicalHash retrieves a hash assigned to a canonical block number.
GetChainConfig will fetch the network settings based on the given hash.
GetHashFn returns a GetHashFunc which retrieves header hashes by number.
GetHeadBlockHash retrieves the hash of the current canonical head block.
GetHeader retrieves the block header corresponding to the hash, nil if none found.
GetHeaderRLP retrieves a block header in its raw RLP database encoding, or nil if the header's not found.
GetHeadFastBlockHash retrieves the hash of the current canonical head block during fast synchronization.
GetHeadHeaderHash retrieves the hash of the current canonical head block's header.
GetMipmapBloom returns a bloom filter using the number and level as input parameters.
GetReceipt returns a receipt by hash.
GetTd retrieves a block's total difficulty corresponding to the hash, nil if none found.
GetTransaction retrieves a specific transaction from the database, along with its added positional metadata.
IntrinsicGas computes the 'intrinsic gas' for a message with the given data.
No description provided by the author
No description provided by the author
IsBlockNonceErr returns true for invalid block nonce errors.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
MakeChainConfig returns a new ChainConfig with the ethereum default chain settings.
No description provided by the author
NewBlockChain returns a fully initialised block chain using information available in the database.
NewBlockValidator returns a new block validator which is safe for re-use.
NewEVMContext creates a new context for use in the EVM.
NewHeaderChain creates a new HeaderChain structure.
NewBlockValidator returns a new block validator which is safe for re-use.
NewStateProcessor initialises a new StateProcessor.
NewStateTransition initialises and returns a new state transition object.
No description provided by the author
No description provided by the author
OlympicGenesisBlock assembles a JSON string representing the Olympic genesis block.
No description provided by the author
SetReceiptsData computes all the non-consensus fields of the receipts.
Transfer subtracts amount from sender and adds amount to recipient using the given Db.
No description provided by the author
ValidateDAOHeaderExtraData validates the extra-data field of a block header to ensure it conforms to DAO hard-fork rules.
Validates a header.
No description provided by the author
No description provided by the author
WriteBlock serializes a block into the database, header and body separately.
WriteBlockChainVersion writes vsn as the version number to db.
WriteBlockReceipts stores all the transaction receipts belonging to a block as a single receipt slice.
WriteBody serializes the body of a block into the database.
WriteBodyRLP writes a serialized body of a block into the database.
WriteCanonicalHash stores the canonical hash for the given block number.
WriteChainConfig writes the chain config settings to the database.
WriteDefaultGenesisBlock assembles the official Ethereum genesis block and writes it - along with all associated state - into a chain database.
WriteGenesisBlock writes the genesis block to the database as block number 0.
No description provided by the author
WriteHeadBlockHash stores the head block's hash.
WriteHeader serializes a block header into the database.
WriteHeadFastBlockHash stores the fast head block's hash.
WriteHeadHeaderHash stores the head header's hash.
WriteMapmapBloom writes each address included in the receipts' logs to the MIP bloom bin.
WriteOlympicGenesisBlock assembles the Olympic genesis block and writes it along with all associated state into a chain database.
WriteReceipt stores a single transaction receipt into the database.
WriteReceipts stores a batch of transaction receipts into the database.
WriteTd serializes the total difficulty of a block into the database.
WriteTestNetGenesisBlock assembles the Morden test network genesis block and writes it - along with all associated state - into a chain database.
WriteTransactions stores the transactions associated with a specific block into the given database.
# Constants
must be bumped when consensus algorithm is changed, this forces the upgradedb command to be run (forces the blocks to be imported again using the new algorithm).
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
# Variables
Set of manually tracked bad hashes (usually hard forks).
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
general config not found error.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
Transaction Pool Errors.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
# Structs
BlockChain represents the canonical chain given a database with a genesis block.
BlockGen creates blocks for testing.
BlockNonceErr indicates that a block's nonce is invalid.
BlockValidator is responsible for validating block headers, uncles and processed state.
No description provided by the author
No description provided by the author
No description provided by the author
ChainSplit is posted when a new head is detected.
No description provided by the author
FakePow is a non-validating proof of work implementation.
No description provided by the author
No description provided by the author
No description provided by the author
HeaderChain implements the basic block header chain logic that is shared by core.BlockChain and light.LightChain.
No description provided by the author
No description provided by the author
NewMinedBlockEvent is posted when a block has been imported.
No description provided by the author
Parent error.
No description provided by the author
PendingLogsEvent is posted pre mining and notifies of pending logs.
PendingStateEvent is posted pre mining and notifies of pending state changes.
RemovedLogEvent is posted when a reorg happens.
RemovedTransactionEvent is posted when a reorg happens.
Mining operation events.
StateProcessor is a basic Processor, which takes care of transitioning state from one point to another.
The State Transitioning Model
A state transition is a change made when a transaction is applied to the current world state
The state transitioning model does all all the necessary work to work out a valid new state root.
No description provided by the author
No description provided by the author
TxPool contains all currently known transactions.
TxPostEvent is posted when a transaction has been processed.
TxPreEvent is posted when a transaction enters the transaction pool.
No description provided by the author
Block validation error.
No description provided by the author
# Interfaces
BlockFetcher retrieves headers by their hash.
HeaderValidator is an interface for validating headers only
ValidateHeader validates the given header and parent and returns an error if it failed to do so.
Message represents a message sent to a contract.
Processor is an interface for processing blocks using a given initial state.
Validator is an interface which defines the standard for block validation.
# Type aliases
No description provided by the author
DeleteCallback is a callback function that is called by SetHead before each header is deleted.
GasPool tracks the amount of gas available during execution of the transactions in a block.
WhCallback is a callback function for inserting individual headers.
No description provided by the author