Trait Rpc

Source
pub trait Rpc<C>
where C: SendRequest, Error<<C as SendRequest>::Error>: From<<C as SendRequest>::Error>,
{ // Required method fn send_request<'life0, 'async_trait, P>( &'life0 self, request: String, ) -> Pin<Box<dyn Future<Output = Result<Response<P>, <C as SendRequest>::Error>> + Send + 'async_trait>> where P: 'async_trait + DeserializeOwned, Self: 'async_trait, 'life0: 'async_trait; // Provided methods fn getbestblockhash<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<BlockHash, Error<<C as SendRequest>::Error>>> + Send + 'async_trait>> where Self: Sync + 'async_trait, 'life0: 'async_trait { ... } fn getblockcount<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<u64, Error<<C as SendRequest>::Error>>> + Send + 'async_trait>> where Self: Sync + 'async_trait, 'life0: 'async_trait { ... } fn generatetoaddress<'life0, 'life1, 'async_trait>( &'life0 self, nblocks: usize, address: &'life1 str, maxtries: Option<u64>, ) -> Pin<Box<dyn Future<Output = Result<Vec<BlockHash>, Error<<C as SendRequest>::Error>>> + Send + 'async_trait>> where Self: Sync + 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait { ... } fn sendtoaddress<'life0, 'life1, 'life2, 'life3, 'life4, 'life5, 'async_trait>( &'life0 self, address: &'life1 str, amount: f64, comment: Option<&'life2 str>, comment_to: Option<&'life3 str>, subtractfeefromamount: Option<bool>, replaceable: Option<bool>, conf_target: Option<u64>, estimate_mode: Option<&'life4 str>, avoid_reuse: Option<bool>, assetlabel: Option<&'life5 str>, ignoreblindfail: Option<bool>, fee_rate: Option<f64>, verbose: Option<bool>, ) -> Pin<Box<dyn Future<Output = Result<SendToAddress, Error<<C as SendRequest>::Error>>> + Send + 'async_trait>> where Self: Sync + 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait, 'life3: 'async_trait, 'life4: 'async_trait, 'life5: 'async_trait { ... } fn estimatesmartfee<'life0, 'life1, 'async_trait>( &'life0 self, conf_target: u64, estimate_mode: &'life1 str, ) -> Pin<Box<dyn Future<Output = Result<EstimateSmartFee, Error<<C as SendRequest>::Error>>> + Send + 'async_trait>> where Self: Sync + 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait { ... } fn createwallet<'life0, 'life1, 'life2, 'async_trait>( &'life0 self, wallet_name: &'life1 str, disable_private_keys: Option<bool>, blank: Option<bool>, passphrase: Option<&'life2 str>, avoid_reuse: Option<bool>, descriptors: Option<bool>, load_on_startup: Option<bool>, external_signer: Option<bool>, ) -> Pin<Box<dyn Future<Output = Result<CreateWallet, Error<<C as SendRequest>::Error>>> + Send + 'async_trait>> where Self: Sync + 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait { ... } fn getaddressinfo<'life0, 'life1, 'async_trait>( &'life0 self, address: &'life1 str, ) -> Pin<Box<dyn Future<Output = Result<AddressInfo, Error<<C as SendRequest>::Error>>> + Send + 'async_trait>> where Self: Sync + 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait { ... } fn getnewaddress<'life0, 'life1, 'life2, 'async_trait>( &'life0 self, label: Option<&'life1 str>, address_type: Option<&'life2 str>, ) -> Pin<Box<dyn Future<Output = Result<String, Error<<C as SendRequest>::Error>>> + Send + 'async_trait>> where Self: Sync + 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait { ... } fn getwalletinfo<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<WalletInfo, Error<<C as SendRequest>::Error>>> + Send + 'async_trait>> where Self: Sync + 'async_trait, 'life0: 'async_trait { ... } }

Required Methods§

Source

fn send_request<'life0, 'async_trait, P>( &'life0 self, request: String, ) -> Pin<Box<dyn Future<Output = Result<Response<P>, <C as SendRequest>::Error>> + Send + 'async_trait>>
where P: 'async_trait + DeserializeOwned, Self: 'async_trait, 'life0: 'async_trait,

Provided Methods§

Source

fn getbestblockhash<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<BlockHash, Error<<C as SendRequest>::Error>>> + Send + 'async_trait>>
where Self: Sync + 'async_trait, 'life0: 'async_trait,

Source

fn getblockcount<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<u64, Error<<C as SendRequest>::Error>>> + Send + 'async_trait>>
where Self: Sync + 'async_trait, 'life0: 'async_trait,

Source

fn generatetoaddress<'life0, 'life1, 'async_trait>( &'life0 self, nblocks: usize, address: &'life1 str, maxtries: Option<u64>, ) -> Pin<Box<dyn Future<Output = Result<Vec<BlockHash>, Error<<C as SendRequest>::Error>>> + Send + 'async_trait>>
where Self: Sync + 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Source

fn sendtoaddress<'life0, 'life1, 'life2, 'life3, 'life4, 'life5, 'async_trait>( &'life0 self, address: &'life1 str, amount: f64, comment: Option<&'life2 str>, comment_to: Option<&'life3 str>, subtractfeefromamount: Option<bool>, replaceable: Option<bool>, conf_target: Option<u64>, estimate_mode: Option<&'life4 str>, avoid_reuse: Option<bool>, assetlabel: Option<&'life5 str>, ignoreblindfail: Option<bool>, fee_rate: Option<f64>, verbose: Option<bool>, ) -> Pin<Box<dyn Future<Output = Result<SendToAddress, Error<<C as SendRequest>::Error>>> + Send + 'async_trait>>
where Self: Sync + 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait, 'life3: 'async_trait, 'life4: 'async_trait, 'life5: 'async_trait,

Source

fn estimatesmartfee<'life0, 'life1, 'async_trait>( &'life0 self, conf_target: u64, estimate_mode: &'life1 str, ) -> Pin<Box<dyn Future<Output = Result<EstimateSmartFee, Error<<C as SendRequest>::Error>>> + Send + 'async_trait>>
where Self: Sync + 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Source

fn createwallet<'life0, 'life1, 'life2, 'async_trait>( &'life0 self, wallet_name: &'life1 str, disable_private_keys: Option<bool>, blank: Option<bool>, passphrase: Option<&'life2 str>, avoid_reuse: Option<bool>, descriptors: Option<bool>, load_on_startup: Option<bool>, external_signer: Option<bool>, ) -> Pin<Box<dyn Future<Output = Result<CreateWallet, Error<<C as SendRequest>::Error>>> + Send + 'async_trait>>
where Self: Sync + 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait,

Source

fn getaddressinfo<'life0, 'life1, 'async_trait>( &'life0 self, address: &'life1 str, ) -> Pin<Box<dyn Future<Output = Result<AddressInfo, Error<<C as SendRequest>::Error>>> + Send + 'async_trait>>
where Self: Sync + 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Source

fn getnewaddress<'life0, 'life1, 'life2, 'async_trait>( &'life0 self, label: Option<&'life1 str>, address_type: Option<&'life2 str>, ) -> Pin<Box<dyn Future<Output = Result<String, Error<<C as SendRequest>::Error>>> + Send + 'async_trait>>
where Self: Sync + 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait,

Source

fn getwalletinfo<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<WalletInfo, Error<<C as SendRequest>::Error>>> + Send + 'async_trait>>
where Self: Sync + 'async_trait, 'life0: 'async_trait,

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§