Trait EngineEthApiClient

Source
pub trait EngineEthApiClient<B, R>: ClientT
where B: RpcObject + Send + Sync + 'static + DeserializeOwned, R: RpcObject + Send + Sync + 'static + DeserializeOwned,
{ // Provided methods fn syncing(&self) -> impl Future<Output = Result<SyncStatus, Error>> + Send { ... } fn chain_id( &self, ) -> impl Future<Output = Result<Option<Uint<64, 1>>, Error>> + Send { ... } fn block_number( &self, ) -> impl Future<Output = Result<Uint<256, 4>, Error>> + Send { ... } fn call( &self, request: TransactionRequest, block_number: Option<BlockId>, state_overrides: Option<HashMap<Address, AccountOverride, FbBuildHasher<20>>>, block_overrides: Option<Box<BlockOverrides>>, ) -> impl Future<Output = Result<Bytes, Error>> + Send { ... } fn get_code( &self, address: Address, block_id: Option<BlockId>, ) -> impl Future<Output = Result<Bytes, Error>> + Send { ... } fn block_by_hash( &self, hash: FixedBytes<32>, full: bool, ) -> impl Future<Output = Result<Option<B>, Error>> + Send { ... } fn block_by_number( &self, number: BlockNumberOrTag, full: bool, ) -> impl Future<Output = Result<Option<B>, Error>> + Send { ... } fn block_receipts( &self, block_id: BlockId, ) -> impl Future<Output = Result<Option<Vec<R>>, Error>> + Send { ... } fn send_raw_transaction( &self, bytes: Bytes, ) -> impl Future<Output = Result<FixedBytes<32>, Error>> + Send { ... } fn transaction_receipt( &self, hash: FixedBytes<32>, ) -> impl Future<Output = Result<Option<R>, Error>> + Send { ... } fn logs( &self, filter: Filter, ) -> impl Future<Output = Result<Vec<Log>, Error>> + Send { ... } fn get_proof( &self, address: Address, keys: Vec<JsonStorageKey>, block_number: Option<BlockId>, ) -> impl Future<Output = Result<EIP1186AccountProofResponse, Error>> + Send { ... } }
Expand description

Client implementation for the EngineEthApi RPC API.

Provided Methods§

Source

fn syncing(&self) -> impl Future<Output = Result<SyncStatus, Error>> + Send

Returns an object with data about the sync status or false.

Source

fn chain_id( &self, ) -> impl Future<Output = Result<Option<Uint<64, 1>>, Error>> + Send

Returns the chain ID of the current network.

Source

fn block_number( &self, ) -> impl Future<Output = Result<Uint<256, 4>, Error>> + Send

Returns the number of most recent block.

Source

fn call( &self, request: TransactionRequest, block_number: Option<BlockId>, state_overrides: Option<HashMap<Address, AccountOverride, FbBuildHasher<20>>>, block_overrides: Option<Box<BlockOverrides>>, ) -> impl Future<Output = Result<Bytes, Error>> + Send

Executes a new message call immediately without creating a transaction on the block chain.

Source

fn get_code( &self, address: Address, block_id: Option<BlockId>, ) -> impl Future<Output = Result<Bytes, Error>> + Send

Returns code at a given address at given block number.

Source

fn block_by_hash( &self, hash: FixedBytes<32>, full: bool, ) -> impl Future<Output = Result<Option<B>, Error>> + Send

Returns information about a block by hash.

Source

fn block_by_number( &self, number: BlockNumberOrTag, full: bool, ) -> impl Future<Output = Result<Option<B>, Error>> + Send

Returns information about a block by number.

Source

fn block_receipts( &self, block_id: BlockId, ) -> impl Future<Output = Result<Option<Vec<R>>, Error>> + Send

Returns all transaction receipts for a given block.

Source

fn send_raw_transaction( &self, bytes: Bytes, ) -> impl Future<Output = Result<FixedBytes<32>, Error>> + Send

Sends signed transaction, returning its hash.

Source

fn transaction_receipt( &self, hash: FixedBytes<32>, ) -> impl Future<Output = Result<Option<R>, Error>> + Send

Returns the receipt of a transaction by transaction hash.

Source

fn logs( &self, filter: Filter, ) -> impl Future<Output = Result<Vec<Log>, Error>> + Send

Returns logs matching given filter object.

Source

fn get_proof( &self, address: Address, keys: Vec<JsonStorageKey>, block_number: Option<BlockId>, ) -> impl Future<Output = Result<EIP1186AccountProofResponse, Error>> + Send

Returns the account and storage values of the specified account including the Merkle-proof. This call can be used to verify that the data you are pulling from is not tampered with.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§

Source§

impl<TypeJsonRpseeInternal, B, R> EngineEthApiClient<B, R> for TypeJsonRpseeInternal
where B: RpcObject + Send + Sync + 'static + DeserializeOwned, R: RpcObject + Send + Sync + 'static + DeserializeOwned, TypeJsonRpseeInternal: ClientT,