reth::rpc::api::servers

Trait TxPoolApiServer

Source
pub trait TxPoolApiServer<T>:
    Sized
    + Send
    + Sync
    + 'static
where T: RpcObject,
{ // Required methods fn txpool_status<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<TxpoolStatus, ErrorObject<'static>>> + Send + 'async_trait>> where 'life0: 'async_trait, Self: 'async_trait; fn txpool_inspect<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<TxpoolInspect, ErrorObject<'static>>> + Send + 'async_trait>> where 'life0: 'async_trait, Self: 'async_trait; fn txpool_content_from<'life0, 'async_trait>( &'life0 self, from: Address, ) -> Pin<Box<dyn Future<Output = Result<TxpoolContentFrom<T>, ErrorObject<'static>>> + Send + 'async_trait>> where 'life0: 'async_trait, Self: 'async_trait; fn txpool_content<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<TxpoolContent<T>, ErrorObject<'static>>> + Send + 'async_trait>> where 'life0: 'async_trait, Self: 'async_trait; // Provided method fn into_rpc(self) -> RpcModule<Self> where T: Send + Sync + 'static + Clone + Serialize { ... } }
Expand description

Server trait implementation for the TxPoolApi RPC API.

Required Methods§

Source

fn txpool_status<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<TxpoolStatus, ErrorObject<'static>>> + Send + 'async_trait>>
where 'life0: 'async_trait, Self: 'async_trait,

Returns the number of transactions currently pending for inclusion in the next block(s), as well as the ones that are being scheduled for future execution only.

See here for more details

Source

fn txpool_inspect<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<TxpoolInspect, ErrorObject<'static>>> + Send + 'async_trait>>
where 'life0: 'async_trait, Self: 'async_trait,

Returns a summary of all the transactions currently pending for inclusion in the next block(s), as well as the ones that are being scheduled for future execution only.

See here for more details

Source

fn txpool_content_from<'life0, 'async_trait>( &'life0 self, from: Address, ) -> Pin<Box<dyn Future<Output = Result<TxpoolContentFrom<T>, ErrorObject<'static>>> + Send + 'async_trait>>
where 'life0: 'async_trait, Self: 'async_trait,

Retrieves the transactions contained within the txpool, returning pending as well as queued transactions of this address, grouped by nonce.

See here for more details

Source

fn txpool_content<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<TxpoolContent<T>, ErrorObject<'static>>> + Send + 'async_trait>>
where 'life0: 'async_trait, Self: 'async_trait,

Returns the details of all transactions currently pending for inclusion in the next block(s), as well as the ones that are being scheduled for future execution only.

See here for more details

Provided Methods§

Source

fn into_rpc(self) -> RpcModule<Self>
where T: Send + Sync + 'static + Clone + Serialize,

Collects all the methods and subscriptions defined in the trait and adds them into a single RpcModule.

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.

Implementations on Foreign Types§

Source§

impl<Pool, Eth> TxPoolApiServer<<Eth as TransactionCompat<<<Pool as TransactionPool>::Transaction as PoolTransaction>::Consensus>>::Transaction> for TxPoolApi<Pool, Eth>

Source§

fn txpool_status<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<TxpoolStatus, ErrorObject<'static>>> + Send + 'async_trait>>
where 'life0: 'async_trait, TxPoolApi<Pool, Eth>: 'async_trait,

Returns the number of transactions currently pending for inclusion in the next block(s), as well as the ones that are being scheduled for future execution only. Ref: Here

Handler for txpool_status

Source§

fn txpool_inspect<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<TxpoolInspect, ErrorObject<'static>>> + Send + 'async_trait>>
where 'life0: 'async_trait, TxPoolApi<Pool, Eth>: 'async_trait,

Returns a summary of all the transactions currently pending for inclusion in the next block(s), as well as the ones that are being scheduled for future execution only.

See here for more details

Handler for txpool_inspect

Source§

fn txpool_content_from<'life0, 'async_trait>( &'life0 self, from: Address, ) -> Pin<Box<dyn Future<Output = Result<TxpoolContentFrom<<Eth as TransactionCompat<<<Pool as TransactionPool>::Transaction as PoolTransaction>::Consensus>>::Transaction>, ErrorObject<'static>>> + Send + 'async_trait>>
where 'life0: 'async_trait, TxPoolApi<Pool, Eth>: 'async_trait,

Retrieves the transactions contained within the txpool, returning pending as well as queued transactions of this address, grouped by nonce.

See here for more details Handler for txpool_contentFrom

Source§

fn txpool_content<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<TxpoolContent<<Eth as TransactionCompat<<<Pool as TransactionPool>::Transaction as PoolTransaction>::Consensus>>::Transaction>, ErrorObject<'static>>> + Send + 'async_trait>>
where 'life0: 'async_trait, TxPoolApi<Pool, Eth>: 'async_trait,

Returns the details of all transactions currently pending for inclusion in the next block(s), as well as the ones that are being scheduled for future execution only.

See here for more details Handler for txpool_content

Implementors§