tuweni / org.apache.tuweni.devp2p.eth / EthClient66

EthClient66

class EthClient66 : EthClient (source)

Client of the ETH subprotocol, allowing to request block and node data

Constructors

<init>

Client of the ETH subprotocol, allowing to request block and node data

EthClient66(service: RLPxService, pendingTransactionsPool: TransactionPool, connectionSelectionStrategy: ConnectionSelectionStrategy)

Functions

bodiesRequested

fun bodiesRequested(requestIdentifier: Bytes): Request<List<BlockBody>>?

connectionSelectionStrategy

Strategy to pick a connection.

fun connectionSelectionStrategy(): ConnectionSelectionStrategy

headersRequested

fun headersRequested(requestIdentifier: Bytes): Request<List<BlockHeader>>?

nodeDataWasRequested

fun nodeDataWasRequested(requestIdentifier: Bytes): Request<List<Bytes?>>?

requestBlock

Requests a block from block hash

fun requestBlock(blockHash: Hash, connection: WireConnection): AsyncResult<Block>

requestBlockBodies

Requests block bodies from block hashes

fun requestBlockBodies(blockHashes: List<Hash>, connection: WireConnection): AsyncResult<List<BlockBody>>

requestBlockHeader

Requests a block header

fun requestBlockHeader(blockHash: Hash, connection: WireConnection): AsyncResult<BlockHeader>

requestBlockHeaders

Requests block headers

fun requestBlockHeaders(blockHash: Hash, maxHeaders: Long, skip: Long, reverse: Boolean, connection: WireConnection): AsyncResult<List<BlockHeader>>
fun requestBlockHeaders(blockNumber: Long, maxHeaders: Long, skip: Long, reverse: Boolean, connection: WireConnection): AsyncResult<List<BlockHeader>>
fun requestBlockHeaders(blockHashes: List<Hash>, connection: WireConnection): AsyncResult<List<BlockHeader>>

requestTransactionReceipts

Requests transaction receipts

fun requestTransactionReceipts(blockHashes: List<Hash>, connection: WireConnection): AsyncResult<List<List<TransactionReceipt>>>

submitPooledTransaction

Submits a new pending transaction to the transaction pool to be gossiped to peers.

suspend fun submitPooledTransaction(vararg tx: Transaction): Unit

transactionReceiptsRequested

fun transactionReceiptsRequested(requestIdentifier: Bytes): Request<List<List<TransactionReceipt>>>?

Companion Object Properties

logger

val logger: Logger!