pub trait CfxDebugRpcServer:
Sized
+ Send
+ Sync
+ 'static {
// Required methods
fn send_transaction<'life0, 'async_trait>(
&'life0 self,
tx: TransactionRequest,
password: Option<String>,
) -> Pin<Box<dyn Future<Output = JsonRpcResult<H256>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn accounts<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = JsonRpcResult<Vec<RpcAddress>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn new_account<'life0, 'async_trait>(
&'life0 self,
password: String,
) -> Pin<Box<dyn Future<Output = JsonRpcResult<RpcAddress>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn unlock_account<'life0, 'async_trait>(
&'life0 self,
address: RpcAddress,
password: String,
duration: Option<U128>,
) -> Pin<Box<dyn Future<Output = JsonRpcResult<bool>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn lock_account<'life0, 'async_trait>(
&'life0 self,
address: RpcAddress,
) -> Pin<Box<dyn Future<Output = JsonRpcResult<bool>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn sign(
&self,
data: RpcBytes,
address: RpcAddress,
password: Option<String>,
) -> JsonRpcResult<H520>;
fn sign_transaction(
&self,
tx: TransactionRequest,
password: Option<String>,
) -> JsonRpcResult<String>;
fn epoch_receipts<'life0, 'async_trait>(
&'life0 self,
epoch: BlockHashOrEpochNumber,
include_eth_receipts: Option<bool>,
) -> Pin<Box<dyn Future<Output = JsonRpcResult<Option<Vec<Vec<RpcReceipt>>>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn account_pending_info<'life0, 'async_trait>(
&'life0 self,
address: RpcAddress,
) -> Pin<Box<dyn Future<Output = JsonRpcResult<Option<AccountPendingInfo>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn account_pending_transactions<'life0, 'async_trait>(
&'life0 self,
address: RpcAddress,
maybe_start_nonce: Option<U256>,
maybe_limit: Option<U64>,
) -> Pin<Box<dyn Future<Output = JsonRpcResult<AccountPendingTransactions>> + 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 CfxDebugRpc RPC API.
Required Methods§
fn send_transaction<'life0, 'async_trait>(
&'life0 self,
tx: TransactionRequest,
password: Option<String>,
) -> Pin<Box<dyn Future<Output = JsonRpcResult<H256>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Sourcefn accounts<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = JsonRpcResult<Vec<RpcAddress>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn accounts<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = JsonRpcResult<Vec<RpcAddress>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Returns accounts list.
Sourcefn new_account<'life0, 'async_trait>(
&'life0 self,
password: String,
) -> Pin<Box<dyn Future<Output = JsonRpcResult<RpcAddress>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn new_account<'life0, 'async_trait>(
&'life0 self,
password: String,
) -> Pin<Box<dyn Future<Output = JsonRpcResult<RpcAddress>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Create a new account
Sourcefn unlock_account<'life0, 'async_trait>(
&'life0 self,
address: RpcAddress,
password: String,
duration: Option<U128>,
) -> Pin<Box<dyn Future<Output = JsonRpcResult<bool>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn unlock_account<'life0, 'async_trait>(
&'life0 self,
address: RpcAddress,
password: String,
duration: Option<U128>,
) -> Pin<Box<dyn Future<Output = JsonRpcResult<bool>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Unlock an account
Sourcefn lock_account<'life0, 'async_trait>(
&'life0 self,
address: RpcAddress,
) -> Pin<Box<dyn Future<Output = JsonRpcResult<bool>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn lock_account<'life0, 'async_trait>(
&'life0 self,
address: RpcAddress,
) -> Pin<Box<dyn Future<Output = JsonRpcResult<bool>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Lock an account
fn sign( &self, data: RpcBytes, address: RpcAddress, password: Option<String>, ) -> JsonRpcResult<H520>
fn sign_transaction( &self, tx: TransactionRequest, password: Option<String>, ) -> JsonRpcResult<String>
fn epoch_receipts<'life0, 'async_trait>(
&'life0 self,
epoch: BlockHashOrEpochNumber,
include_eth_receipts: Option<bool>,
) -> Pin<Box<dyn Future<Output = JsonRpcResult<Option<Vec<Vec<RpcReceipt>>>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Sourcefn account_pending_info<'life0, 'async_trait>(
&'life0 self,
address: RpcAddress,
) -> Pin<Box<dyn Future<Output = JsonRpcResult<Option<AccountPendingInfo>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn account_pending_info<'life0, 'async_trait>(
&'life0 self,
address: RpcAddress,
) -> Pin<Box<dyn Future<Output = JsonRpcResult<Option<AccountPendingInfo>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Get transaction pending info by account address
Sourcefn account_pending_transactions<'life0, 'async_trait>(
&'life0 self,
address: RpcAddress,
maybe_start_nonce: Option<U256>,
maybe_limit: Option<U64>,
) -> Pin<Box<dyn Future<Output = JsonRpcResult<AccountPendingTransactions>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn account_pending_transactions<'life0, 'async_trait>(
&'life0 self,
address: RpcAddress,
maybe_start_nonce: Option<U256>,
maybe_limit: Option<U64>,
) -> Pin<Box<dyn Future<Output = JsonRpcResult<AccountPendingTransactions>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Get transaction pending info by account address
Provided Methods§
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.