Trait sc_rpc::state::ChildStateApiClient
source · pub trait ChildStateApiClient<Hash>: ClientTwhere
Hash: Send + Sync + 'static + Serialize + DeserializeOwned,{
// Provided methods
fn storage_keys<'life0, 'async_trait>(
&'life0 self,
child_storage_key: PrefixedStorageKey,
prefix: StorageKey,
hash: Option<Hash>
) -> Pin<Box<dyn Future<Output = Result<Vec<StorageKey, Global>, Error>> + Send + 'async_trait, Global>>
where 'life0: 'async_trait,
Self: Sync + 'async_trait { ... }
fn storage_keys_paged<'life0, 'async_trait>(
&'life0 self,
child_storage_key: PrefixedStorageKey,
prefix: Option<StorageKey>,
count: u32,
start_key: Option<StorageKey>,
hash: Option<Hash>
) -> Pin<Box<dyn Future<Output = Result<Vec<StorageKey, Global>, Error>> + Send + 'async_trait, Global>>
where 'life0: 'async_trait,
Self: Sync + 'async_trait { ... }
fn storage<'life0, 'async_trait>(
&'life0 self,
child_storage_key: PrefixedStorageKey,
key: StorageKey,
hash: Option<Hash>
) -> Pin<Box<dyn Future<Output = Result<Option<StorageData>, Error>> + Send + 'async_trait, Global>>
where 'life0: 'async_trait,
Self: Sync + 'async_trait { ... }
fn storage_entries<'life0, 'async_trait>(
&'life0 self,
child_storage_key: PrefixedStorageKey,
keys: Vec<StorageKey, Global>,
hash: Option<Hash>
) -> Pin<Box<dyn Future<Output = Result<Vec<Option<StorageData>, Global>, Error>> + Send + 'async_trait, Global>>
where 'life0: 'async_trait,
Self: Sync + 'async_trait { ... }
fn storage_hash<'life0, 'async_trait>(
&'life0 self,
child_storage_key: PrefixedStorageKey,
key: StorageKey,
hash: Option<Hash>
) -> Pin<Box<dyn Future<Output = Result<Option<Hash>, Error>> + Send + 'async_trait, Global>>
where 'life0: 'async_trait,
Self: Sync + 'async_trait { ... }
fn storage_size<'life0, 'async_trait>(
&'life0 self,
child_storage_key: PrefixedStorageKey,
key: StorageKey,
hash: Option<Hash>
) -> Pin<Box<dyn Future<Output = Result<Option<u64>, Error>> + Send + 'async_trait, Global>>
where 'life0: 'async_trait,
Self: Sync + 'async_trait { ... }
fn read_child_proof<'life0, 'async_trait>(
&'life0 self,
child_storage_key: PrefixedStorageKey,
keys: Vec<StorageKey, Global>,
hash: Option<Hash>
) -> Pin<Box<dyn Future<Output = Result<ReadProof<Hash>, Error>> + Send + 'async_trait, Global>>
where 'life0: 'async_trait,
Self: Sync + 'async_trait { ... }
}
Expand description
Client implementation for the ChildStateApi
RPC API.
Provided Methods§
sourcefn storage_keys<'life0, 'async_trait>(
&'life0 self,
child_storage_key: PrefixedStorageKey,
prefix: StorageKey,
hash: Option<Hash>
) -> Pin<Box<dyn Future<Output = Result<Vec<StorageKey, Global>, Error>> + Send + 'async_trait, Global>>where
'life0: 'async_trait,
Self: Sync + 'async_trait,
fn storage_keys<'life0, 'async_trait>( &'life0 self, child_storage_key: PrefixedStorageKey, prefix: StorageKey, hash: Option<Hash> ) -> Pin<Box<dyn Future<Output = Result<Vec<StorageKey, Global>, Error>> + Send + 'async_trait, Global>>where 'life0: 'async_trait, Self: Sync + 'async_trait,
👎Deprecated since 2.0.0: Please use
getKeysPaged
with proper paging supportReturns the keys with prefix from a child storage, leave empty to get all the keys
sourcefn storage_keys_paged<'life0, 'async_trait>(
&'life0 self,
child_storage_key: PrefixedStorageKey,
prefix: Option<StorageKey>,
count: u32,
start_key: Option<StorageKey>,
hash: Option<Hash>
) -> Pin<Box<dyn Future<Output = Result<Vec<StorageKey, Global>, Error>> + Send + 'async_trait, Global>>where
'life0: 'async_trait,
Self: Sync + 'async_trait,
fn storage_keys_paged<'life0, 'async_trait>( &'life0 self, child_storage_key: PrefixedStorageKey, prefix: Option<StorageKey>, count: u32, start_key: Option<StorageKey>, hash: Option<Hash> ) -> Pin<Box<dyn Future<Output = Result<Vec<StorageKey, Global>, Error>> + Send + 'async_trait, Global>>where 'life0: 'async_trait, Self: Sync + 'async_trait,
Returns the keys with prefix from a child storage with pagination support.
Up to count
keys will be returned.
If start_key
is passed, return next keys in storage in lexicographic order.
sourcefn storage<'life0, 'async_trait>(
&'life0 self,
child_storage_key: PrefixedStorageKey,
key: StorageKey,
hash: Option<Hash>
) -> Pin<Box<dyn Future<Output = Result<Option<StorageData>, Error>> + Send + 'async_trait, Global>>where
'life0: 'async_trait,
Self: Sync + 'async_trait,
fn storage<'life0, 'async_trait>( &'life0 self, child_storage_key: PrefixedStorageKey, key: StorageKey, hash: Option<Hash> ) -> Pin<Box<dyn Future<Output = Result<Option<StorageData>, Error>> + Send + 'async_trait, Global>>where 'life0: 'async_trait, Self: Sync + 'async_trait,
Returns a child storage entry at a specific block’s state.
sourcefn storage_entries<'life0, 'async_trait>(
&'life0 self,
child_storage_key: PrefixedStorageKey,
keys: Vec<StorageKey, Global>,
hash: Option<Hash>
) -> Pin<Box<dyn Future<Output = Result<Vec<Option<StorageData>, Global>, Error>> + Send + 'async_trait, Global>>where
'life0: 'async_trait,
Self: Sync + 'async_trait,
fn storage_entries<'life0, 'async_trait>( &'life0 self, child_storage_key: PrefixedStorageKey, keys: Vec<StorageKey, Global>, hash: Option<Hash> ) -> Pin<Box<dyn Future<Output = Result<Vec<Option<StorageData>, Global>, Error>> + Send + 'async_trait, Global>>where 'life0: 'async_trait, Self: Sync + 'async_trait,
Returns child storage entries for multiple keys at a specific block’s state.
sourcefn storage_hash<'life0, 'async_trait>(
&'life0 self,
child_storage_key: PrefixedStorageKey,
key: StorageKey,
hash: Option<Hash>
) -> Pin<Box<dyn Future<Output = Result<Option<Hash>, Error>> + Send + 'async_trait, Global>>where
'life0: 'async_trait,
Self: Sync + 'async_trait,
fn storage_hash<'life0, 'async_trait>( &'life0 self, child_storage_key: PrefixedStorageKey, key: StorageKey, hash: Option<Hash> ) -> Pin<Box<dyn Future<Output = Result<Option<Hash>, Error>> + Send + 'async_trait, Global>>where 'life0: 'async_trait, Self: Sync + 'async_trait,
Returns the hash of a child storage entry at a block’s state.
sourcefn storage_size<'life0, 'async_trait>(
&'life0 self,
child_storage_key: PrefixedStorageKey,
key: StorageKey,
hash: Option<Hash>
) -> Pin<Box<dyn Future<Output = Result<Option<u64>, Error>> + Send + 'async_trait, Global>>where
'life0: 'async_trait,
Self: Sync + 'async_trait,
fn storage_size<'life0, 'async_trait>( &'life0 self, child_storage_key: PrefixedStorageKey, key: StorageKey, hash: Option<Hash> ) -> Pin<Box<dyn Future<Output = Result<Option<u64>, Error>> + Send + 'async_trait, Global>>where 'life0: 'async_trait, Self: Sync + 'async_trait,
Returns the size of a child storage entry at a block’s state.
sourcefn read_child_proof<'life0, 'async_trait>(
&'life0 self,
child_storage_key: PrefixedStorageKey,
keys: Vec<StorageKey, Global>,
hash: Option<Hash>
) -> Pin<Box<dyn Future<Output = Result<ReadProof<Hash>, Error>> + Send + 'async_trait, Global>>where
'life0: 'async_trait,
Self: Sync + 'async_trait,
fn read_child_proof<'life0, 'async_trait>( &'life0 self, child_storage_key: PrefixedStorageKey, keys: Vec<StorageKey, Global>, hash: Option<Hash> ) -> Pin<Box<dyn Future<Output = Result<ReadProof<Hash>, Error>> + Send + 'async_trait, Global>>where 'life0: 'async_trait, Self: Sync + 'async_trait,
Returns proof of storage for child key entries at a specific block’s state.