UNPKG

deth

Version:

Ethereum node focused on Developer Experience

16 lines (15 loc) 466 B
import Block from 'ethereumjs-block'; import { Quantity, Hash } from '../../primitives'; /** * Simple, in memory, copyable blockchain */ export declare class DethBlockchain { private blocks; constructor(blocks?: Block[]); getBlockByNumber(blockNumber: Quantity): Block; getBlockByHash(hash: Hash): Block; putBlock(block: Block): Block; putGenesis(block: Block): Block; getLatestBlock(): Block | undefined; copy(): DethBlockchain; }