pub trait MsaApiClient<BlockHash, AccountId>: ClientTwhere
BlockHash: Send + Sync + 'static,
AccountId: Send + Sync + 'static + Serialize + DeserializeOwned,{
// Provided methods
fn check_delegations<'life0, 'async_trait>(
&'life0 self,
delegator_msa_ids: Vec<DelegatorId>,
provider_msa_id: ProviderId,
block_number: BlockNumber,
schema_id: Option<SchemaId>,
) -> Pin<Box<dyn Future<Output = Result<Vec<(DelegatorId, bool)>, Error>> + Send + 'async_trait>>
where Self: Sync + 'async_trait,
'life0: 'async_trait { ... }
fn get_granted_schemas_by_msa_id<'life0, 'async_trait>(
&'life0 self,
delegator_msa_id: DelegatorId,
provider_msa_id: ProviderId,
) -> Pin<Box<dyn Future<Output = Result<Option<Vec<SchemaGrant<SchemaId, BlockNumber>>>, Error>> + Send + 'async_trait>>
where Self: Sync + 'async_trait,
'life0: 'async_trait { ... }
fn get_all_granted_delegations_by_msa_id<'life0, 'async_trait>(
&'life0 self,
delegator_msa_id: DelegatorId,
) -> Pin<Box<dyn Future<Output = Result<Vec<DelegationResponse<SchemaId, BlockNumber>>, Error>> + Send + 'async_trait>>
where Self: Sync + 'async_trait,
'life0: 'async_trait { ... }
fn get_keys_by_msa_id<'life0, 'async_trait>(
&'life0 self,
msa_id: MessageSourceId,
) -> Pin<Box<dyn Future<Output = Result<Option<KeyInfoResponse<AccountId>>, Error>> + Send + 'async_trait>>
where Self: Sync + 'async_trait,
'life0: 'async_trait { ... }
fn set_keys_by_msa_id<'life0, 'async_trait>(
&'life0 self,
msa_id: MessageSourceId,
public_keys: Vec<AccountId>,
signature_hex: String,
) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>>
where Self: Sync + 'async_trait,
'life0: 'async_trait { ... }
}
Expand description
Client implementation for the MsaApi
RPC API.
Provided Methods§
Sourcefn check_delegations<'life0, 'async_trait>(
&'life0 self,
delegator_msa_ids: Vec<DelegatorId>,
provider_msa_id: ProviderId,
block_number: BlockNumber,
schema_id: Option<SchemaId>,
) -> Pin<Box<dyn Future<Output = Result<Vec<(DelegatorId, bool)>, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
fn check_delegations<'life0, 'async_trait>(
&'life0 self,
delegator_msa_ids: Vec<DelegatorId>,
provider_msa_id: ProviderId,
block_number: BlockNumber,
schema_id: Option<SchemaId>,
) -> Pin<Box<dyn Future<Output = Result<Vec<(DelegatorId, bool)>, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
Check for a list of delegations Given a single provider, test a list of potential delegators At a given block number
Sourcefn get_granted_schemas_by_msa_id<'life0, 'async_trait>(
&'life0 self,
delegator_msa_id: DelegatorId,
provider_msa_id: ProviderId,
) -> Pin<Box<dyn Future<Output = Result<Option<Vec<SchemaGrant<SchemaId, BlockNumber>>>, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
fn get_granted_schemas_by_msa_id<'life0, 'async_trait>(
&'life0 self,
delegator_msa_id: DelegatorId,
provider_msa_id: ProviderId,
) -> Pin<Box<dyn Future<Output = Result<Option<Vec<SchemaGrant<SchemaId, BlockNumber>>>, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
Retrieve the list of currently granted schemas given a delegator and provider pair
Sourcefn get_all_granted_delegations_by_msa_id<'life0, 'async_trait>(
&'life0 self,
delegator_msa_id: DelegatorId,
) -> Pin<Box<dyn Future<Output = Result<Vec<DelegationResponse<SchemaId, BlockNumber>>, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
fn get_all_granted_delegations_by_msa_id<'life0, 'async_trait>(
&'life0 self,
delegator_msa_id: DelegatorId,
) -> Pin<Box<dyn Future<Output = Result<Vec<DelegationResponse<SchemaId, BlockNumber>>, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
Retrieve the list of all delegations for a MsaId
Sourcefn get_keys_by_msa_id<'life0, 'async_trait>(
&'life0 self,
msa_id: MessageSourceId,
) -> Pin<Box<dyn Future<Output = Result<Option<KeyInfoResponse<AccountId>>, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
fn get_keys_by_msa_id<'life0, 'async_trait>(
&'life0 self,
msa_id: MessageSourceId,
) -> Pin<Box<dyn Future<Output = Result<Option<KeyInfoResponse<AccountId>>, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
Retrieve the list of keys for msa id
Sourcefn set_keys_by_msa_id<'life0, 'async_trait>(
&'life0 self,
msa_id: MessageSourceId,
public_keys: Vec<AccountId>,
signature_hex: String,
) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
fn set_keys_by_msa_id<'life0, 'async_trait>(
&'life0 self,
msa_id: MessageSourceId,
public_keys: Vec<AccountId>,
signature_hex: String,
) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
Set the list of keys for msa id
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.