Ƭ BufferLike: Buffer
| TransformableToBuffer | PrefixedHexString | number
Defined in types.ts:42
A Buffer, hex string prefixed with 0x
, Number, or an object with a toBuffer method such as BN.
Ƭ PrefixedHexString: string
Defined in types.ts:37
A hex string prefixed with 0x
.
▸ blockFromRpc(blockParams: any
, uncles?: any
[], chainOptions?: ChainOptions): Block
Defined in from-rpc.ts:14
Creates a new block object from Ethereum JSON RPC.
Parameters:
Name | Type | Description |
---|---|---|
blockParams | any |
Ethereum JSON RPC of block (eth_getBlockByNumber) |
Optional uncles |
any [] |
Optional list of Ethereum JSON RPC of uncles (eth_getUncleByBlockHashAndIndex) |
Optional chainOptions |
ChainOptions | An object describing the blockchain |
Returns: Block
▸ blockHeaderFromRpc(blockParams: any
, chainOptions?: ChainOptions): BlockHeader
Defined in header-from-rpc.ts:11
Creates a new block header object from Ethereum JSON RPC.
Parameters:
Name | Type | Description |
---|---|---|
blockParams | any |
Ethereum JSON RPC of block (eth_getBlockByNumber) |
Optional chainOptions |
ChainOptions | An object describing the blockchain |
Returns: BlockHeader