pub struct Client { /* private fields */ }
Implementations§
Source§impl Client
impl Client
pub fn new(base_url: String) -> Self
pub fn for_network(network: Network) -> Self
pub fn for_shasta() -> Self
pub fn for_main() -> Self
pub async fn get_node_info(&self) -> Result<NodeInfo, Error>
pub async fn list_nodes(&self) -> Result<NodeList, Error>
pub async fn list_witnesses(&self) -> Result<WitnessList, Error>
pub async fn get_chain_parameters(&self) -> Result<ChainParameters, Error>
pub async fn get_block_by_num(&self, num: u64) -> Result<Block, Error>
pub async fn get_block_by_id(&self, id: &str) -> Result<Block, Error>
pub async fn get_now_block(&self) -> Result<Block, Error>
pub async fn get_block_by_latest_num( &self, num: u64, ) -> Result<BlockList, Error>
pub async fn get_block_by_limit_next( &self, start_num: u64, end_num: u64, ) -> Result<BlockList, Error>
pub async fn get_account(&self, address: Address) -> Result<Account, Error>
pub async fn get_account_net( &self, address: Address, ) -> Result<AccountNet, Error>
pub async fn get_transaction_by_id( &self, tx_id: TxId, ) -> Result<Transaction, Error>
pub async fn get_transaction_info_by_id( &self, tx_id: TxId, ) -> Result<TransactionInfo, Error>
pub async fn get_contract(&self, address: Address) -> Result<Contract, Error>
pub async fn get_asset_issue_list(&self) -> Result<AssetIssueList, Error>
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Client
impl !RefUnwindSafe for Client
impl Send for Client
impl Sync for Client
impl Unpin for Client
impl !UnwindSafe for Client
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more