Copyright | Alexander Krupenkin 2016 |
---|---|
License | BSD3 |
Maintainer | mail@akru.me |
Stability | experimental |
Portability | portable |
Safe Haskell | None |
Language | Haskell2010 |
Ethereum generic JSON-RPC types.
- newtype Quantity = Quantity {}
- newtype BlockNumber = BlockNumber Integer
- data SyncActive = SyncActive {}
- data SyncingState
- newtype FilterId = FilterId Integer
- data Change = Change {}
- data Call = Call {}
- data DefaultBlock
- data Filter e = Filter {
- filterAddress :: !(Maybe Address)
- filterTopics :: !(Maybe [Maybe Bytes])
- filterFromBlock :: !DefaultBlock
- filterToBlock :: !DefaultBlock
- data Transaction = Transaction {
- txHash :: !Bytes
- txNonce :: !Quantity
- txBlockHash :: !Bytes
- txBlockNumber :: !BlockNumber
- txTransactionIndex :: !Quantity
- txFrom :: !Address
- txTo :: !(Maybe Address)
- txValue :: !Quantity
- txGasPrice :: !Quantity
- txGas :: !Quantity
- txInput :: !Bytes
- data Block = Block {
- blockNumber :: !BlockNumber
- blockHash :: !Bytes
- blockParentHash :: !Bytes
- blockNonce :: !(Maybe Bytes)
- blockSha3Uncles :: !Bytes
- blockLogsBloom :: !Bytes
- blockTransactionsRoot :: !Bytes
- blockStateRoot :: !Bytes
- blockReceiptRoot :: !(Maybe Bytes)
- blockMiner :: !Address
- blockDifficulty :: !Quantity
- blockTotalDifficulty :: !Quantity
- blockExtraData :: !Bytes
- blockSize :: !Quantity
- blockGasLimit :: !Quantity
- blockGasUsed :: !Quantity
- blockTimestamp :: !Quantity
- blockTransactions :: ![Transaction]
- blockUncles :: ![Bytes]
- type TxHash = Bytes
Documentation
Should be viewed as type to representing QUANTITY in Web3 JSON RPC docs
When encoding QUANTITIES (integers, numbers): encode as hex, prefix with "0x", the most compact representation (slight exception: zero should be represented as "0x0"). Examples:
0x41 (65 in decimal) 0x400 (1024 in decimal) WRONG: 0x (should always have at least one digit - zero is "0x0") WRONG: 0x0400 (no leading zeroes allowed) WRONG: ff (must be prefixed 0x)
newtype BlockNumber Source #
data SyncActive Source #
data SyncingState Source #
Event filter identifier
Changes pulled by low-level call eth_getFilterChanges
, eth_getLogs
,
and eth_getFilterLogs
Change | |
|
The contract call params
data DefaultBlock Source #
The contract call mode describe used state: latest or pending
Low-level event filter data structure
Filter | |
|
data Transaction Source #
Transaction information
Transaction | |
|
Block information
Block | |
|