pub struct JsonRpcClientWrapper { /* private fields */ }
Expand description
A wrapper around JSON RPC for error handling
Implementations§
source§impl JsonRpcClientWrapper
impl JsonRpcClientWrapper
pub fn new(host: String) -> JsonRpcClientWrapper
pub fn submit_transaction( &self, transaction: SignedTransaction ) -> Result<TransactionContext, Error>
pub fn account_state( &self, account: AccountAddress ) -> Result<AccountState, Error>
pub fn validator_config( &self, account: AccountAddress ) -> Result<ValidatorConfigResource, Error>
sourcepub fn validator_set(
&self,
account: Option<AccountAddress>
) -> Result<Vec<ValidatorInfo>, Error>
pub fn validator_set( &self, account: Option<AccountAddress> ) -> Result<Vec<ValidatorInfo>, Error>
This method returns all validator infos currently registered in the validator set of the Diem blockchain. If account is specified, only a single validator info is returned: the one that matches the given account.