Trait EthTransactionApiServer

Source
pub trait EthTransactionApiServer:
    Sized
    + Send
    + Sync
    + 'static {
    // Required methods
    fn transaction_by_hash<'life0, 'async_trait>(
        &'life0 self,
        transaction_hash: H256,
    ) -> Pin<Box<dyn Future<Output = RpcResult<Option<Transaction>>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn transaction_by_block_hash_and_index<'life0, 'async_trait>(
        &'life0 self,
        block_hash: H256,
        transaction_index: Index,
    ) -> Pin<Box<dyn Future<Output = RpcResult<Option<Transaction>>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn transaction_by_block_number_and_index<'life0, 'async_trait>(
        &'life0 self,
        block: BlockNumberOrTag,
        transaction_index: Index,
    ) -> Pin<Box<dyn Future<Output = RpcResult<Option<Transaction>>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn transaction_receipt<'life0, 'async_trait>(
        &'life0 self,
        transaction_hash: H256,
    ) -> Pin<Box<dyn Future<Output = RpcResult<Option<TransactionReceipt>>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;

    // Provided method
    fn into_rpc(self) -> RpcModule<Self> { ... }
}
Expand description

Server trait implementation for the EthTransactionApi RPC API.

Required Methods§

Source

fn transaction_by_hash<'life0, 'async_trait>( &'life0 self, transaction_hash: H256, ) -> Pin<Box<dyn Future<Output = RpcResult<Option<Transaction>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Returns the information about a transaction requested by transaction hash.

Source

fn transaction_by_block_hash_and_index<'life0, 'async_trait>( &'life0 self, block_hash: H256, transaction_index: Index, ) -> Pin<Box<dyn Future<Output = RpcResult<Option<Transaction>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Returns information about a transaction by block hash and transaction index position.

Source

fn transaction_by_block_number_and_index<'life0, 'async_trait>( &'life0 self, block: BlockNumberOrTag, transaction_index: Index, ) -> Pin<Box<dyn Future<Output = RpcResult<Option<Transaction>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Returns information about a transaction by block number and transaction index position.

Source

fn transaction_receipt<'life0, 'async_trait>( &'life0 self, transaction_hash: H256, ) -> Pin<Box<dyn Future<Output = RpcResult<Option<TransactionReceipt>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Returns the receipt of a transaction by transaction hash.

Provided Methods§

Source

fn into_rpc(self) -> RpcModule<Self>

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.

Implementors§