pub trait RpcClient: SubscriptionClientT {
Show 29 methods
// Provided methods
fn parameters<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<VersionedParameters, Error>> + Send + 'async_trait>>
where Self: Sync + 'async_trait,
'life0: 'async_trait { ... }
fn best_block<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<BlockDesc, Error>> + Send + 'async_trait>>
where Self: Sync + 'async_trait,
'life0: 'async_trait { ... }
fn finalized_block<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<BlockDesc, Error>> + Send + 'async_trait>>
where Self: Sync + 'async_trait,
'life0: 'async_trait { ... }
fn parent<'life0, 'async_trait>(
&'life0 self,
header_hash: HeaderHash,
) -> Pin<Box<dyn Future<Output = Result<BlockDesc, Error>> + Send + 'async_trait>>
where Self: Sync + 'async_trait,
'life0: 'async_trait { ... }
fn state_root<'life0, 'async_trait>(
&'life0 self,
header_hash: HeaderHash,
) -> Pin<Box<dyn Future<Output = Result<StateRootHash, Error>> + Send + 'async_trait>>
where Self: Sync + 'async_trait,
'life0: 'async_trait { ... }
fn beefy_root<'life0, 'async_trait>(
&'life0 self,
header_hash: HeaderHash,
) -> Pin<Box<dyn Future<Output = Result<MmrPeakHash, Error>> + Send + 'async_trait>>
where Self: Sync + 'async_trait,
'life0: 'async_trait { ... }
fn statistics<'life0, 'async_trait>(
&'life0 self,
header_hash: HeaderHash,
) -> Pin<Box<dyn Future<Output = Result<AnyBytes, Error>> + Send + 'async_trait>>
where Self: Sync + 'async_trait,
'life0: 'async_trait { ... }
fn service_data<'life0, 'async_trait>(
&'life0 self,
header_hash: HeaderHash,
id: ServiceId,
) -> Pin<Box<dyn Future<Output = Result<Option<AnyBytes>, Error>> + Send + 'async_trait>>
where Self: Sync + 'async_trait,
'life0: 'async_trait { ... }
fn service_value<'life0, 'async_trait>(
&'life0 self,
header_hash: HeaderHash,
id: ServiceId,
key: AnyVec,
) -> Pin<Box<dyn Future<Output = Result<Option<AnyBytes>, Error>> + Send + 'async_trait>>
where Self: Sync + 'async_trait,
'life0: 'async_trait { ... }
fn service_preimage<'life0, 'async_trait>(
&'life0 self,
header_hash: HeaderHash,
id: ServiceId,
hash: AnyHash,
) -> Pin<Box<dyn Future<Output = Result<Option<AnyBytes>, Error>> + Send + 'async_trait>>
where Self: Sync + 'async_trait,
'life0: 'async_trait { ... }
fn service_request<'life0, 'async_trait>(
&'life0 self,
header_hash: HeaderHash,
id: ServiceId,
hash: AnyHash,
len: u32,
) -> Pin<Box<dyn Future<Output = Result<Option<Vec<Slot>>, Error>> + Send + 'async_trait>>
where Self: Sync + 'async_trait,
'life0: 'async_trait { ... }
fn work_report<'life0, 'async_trait>(
&'life0 self,
hash: WorkReportHash,
) -> Pin<Box<dyn Future<Output = Result<AnyBytes, Error>> + Send + 'async_trait>>
where Self: Sync + 'async_trait,
'life0: 'async_trait { ... }
fn submit_work_package<'life0, 'async_trait>(
&'life0 self,
core: CoreIndex,
package: AnyBytes,
extrinsics: Vec<AnyBytes>,
) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>>
where Self: Sync + 'async_trait,
'life0: 'async_trait { ... }
fn submit_work_package_bundle<'life0, 'async_trait>(
&'life0 self,
core: CoreIndex,
bundle: AnyBytes,
) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>>
where Self: Sync + 'async_trait,
'life0: 'async_trait { ... }
fn work_package_status<'life0, 'async_trait>(
&'life0 self,
header_hash: HeaderHash,
hash: WorkPackageHash,
anchor: HeaderHash,
) -> Pin<Box<dyn Future<Output = Result<WorkPackageStatus, Error>> + Send + 'async_trait>>
where Self: Sync + 'async_trait,
'life0: 'async_trait { ... }
fn submit_preimage<'life0, 'async_trait>(
&'life0 self,
requester: ServiceId,
preimage: AnyBytes,
) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>>
where Self: Sync + 'async_trait,
'life0: 'async_trait { ... }
fn list_services<'life0, 'async_trait>(
&'life0 self,
header_hash: HeaderHash,
) -> Pin<Box<dyn Future<Output = Result<Vec<ServiceId>, Error>> + Send + 'async_trait>>
where Self: Sync + 'async_trait,
'life0: 'async_trait { ... }
fn fetch_work_package_segments<'life0, 'async_trait>(
&'life0 self,
wp_hash: WorkPackageHash,
indices: Vec<u16>,
) -> Pin<Box<dyn Future<Output = Result<Vec<WrappedSegment>, Error>> + Send + 'async_trait>>
where Self: Sync + 'async_trait,
'life0: 'async_trait { ... }
fn fetch_segments<'life0, 'async_trait>(
&'life0 self,
segment_root: SegmentTreeRoot,
indices: Vec<u16>,
) -> Pin<Box<dyn Future<Output = Result<Vec<WrappedSegment>, Error>> + Send + 'async_trait>>
where Self: Sync + 'async_trait,
'life0: 'async_trait { ... }
fn sync_state<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<SyncState, Error>> + Send + 'async_trait>>
where Self: Sync + 'async_trait,
'life0: 'async_trait { ... }
fn subscribe_best_block<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Subscription<BlockDesc>, Error>> + Send + 'async_trait>>
where Self: Sync + 'async_trait,
'life0: 'async_trait { ... }
fn subscribe_finalized_block<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Subscription<BlockDesc>, Error>> + Send + 'async_trait>>
where Self: Sync + 'async_trait,
'life0: 'async_trait { ... }
fn subscribe_statistics<'life0, 'async_trait>(
&'life0 self,
finalized: bool,
) -> Pin<Box<dyn Future<Output = Result<Subscription<ChainSubUpdate<AnyBytes>>, Error>> + Send + 'async_trait>>
where Self: Sync + 'async_trait,
'life0: 'async_trait { ... }
fn subscribe_service_data<'life0, 'async_trait>(
&'life0 self,
id: ServiceId,
finalized: bool,
) -> Pin<Box<dyn Future<Output = Result<Subscription<ChainSubUpdate<Option<AnyBytes>>>, Error>> + Send + 'async_trait>>
where Self: Sync + 'async_trait,
'life0: 'async_trait { ... }
fn subscribe_service_value<'life0, 'async_trait>(
&'life0 self,
id: ServiceId,
key: AnyVec,
finalized: bool,
) -> Pin<Box<dyn Future<Output = Result<Subscription<ChainSubUpdate<Option<AnyBytes>>>, Error>> + Send + 'async_trait>>
where Self: Sync + 'async_trait,
'life0: 'async_trait { ... }
fn subscribe_service_preimage<'life0, 'async_trait>(
&'life0 self,
id: ServiceId,
hash: AnyHash,
finalized: bool,
) -> Pin<Box<dyn Future<Output = Result<Subscription<ChainSubUpdate<Option<AnyBytes>>>, Error>> + Send + 'async_trait>>
where Self: Sync + 'async_trait,
'life0: 'async_trait { ... }
fn subscribe_service_request<'life0, 'async_trait>(
&'life0 self,
id: ServiceId,
hash: AnyHash,
len: u32,
finalized: bool,
) -> Pin<Box<dyn Future<Output = Result<Subscription<ChainSubUpdate<Option<Vec<Slot>>>>, Error>> + Send + 'async_trait>>
where Self: Sync + 'async_trait,
'life0: 'async_trait { ... }
fn subscribe_work_package_status<'life0, 'async_trait>(
&'life0 self,
hash: WorkPackageHash,
anchor: HeaderHash,
finalized: bool,
) -> Pin<Box<dyn Future<Output = Result<Subscription<ChainSubUpdate<WorkPackageStatus>>, Error>> + Send + 'async_trait>>
where Self: Sync + 'async_trait,
'life0: 'async_trait { ... }
fn subscribe_sync_status<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Subscription<SyncStatus>, Error>> + Send + 'async_trait>>
where Self: Sync + 'async_trait,
'life0: 'async_trait { ... }
}Expand description
Client implementation for the Rpc RPC API.
Provided Methods§
Sourcefn parameters<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<VersionedParameters, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
fn parameters<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<VersionedParameters, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
Returns the chain parameters.
Sourcefn best_block<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<BlockDesc, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
fn best_block<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<BlockDesc, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
Returns the header hash and slot of the head of the “best” chain.
Sourcefn finalized_block<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<BlockDesc, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
fn finalized_block<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<BlockDesc, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
Returns the header hash and slot of the latest finalized block.
Sourcefn parent<'life0, 'async_trait>(
&'life0 self,
header_hash: HeaderHash,
) -> Pin<Box<dyn Future<Output = Result<BlockDesc, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
fn parent<'life0, 'async_trait>(
&'life0 self,
header_hash: HeaderHash,
) -> Pin<Box<dyn Future<Output = Result<BlockDesc, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
Returns the header hash and slot of the parent of the block with the given header hash.
Sourcefn state_root<'life0, 'async_trait>(
&'life0 self,
header_hash: HeaderHash,
) -> Pin<Box<dyn Future<Output = Result<StateRootHash, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
fn state_root<'life0, 'async_trait>(
&'life0 self,
header_hash: HeaderHash,
) -> Pin<Box<dyn Future<Output = Result<StateRootHash, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
Returns the posterior state root of the block with the given header hash.
Sourcefn beefy_root<'life0, 'async_trait>(
&'life0 self,
header_hash: HeaderHash,
) -> Pin<Box<dyn Future<Output = Result<MmrPeakHash, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
fn beefy_root<'life0, 'async_trait>(
&'life0 self,
header_hash: HeaderHash,
) -> Pin<Box<dyn Future<Output = Result<MmrPeakHash, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
Returns the BEEFY root of the block with the given header hash.
Sourcefn statistics<'life0, 'async_trait>(
&'life0 self,
header_hash: HeaderHash,
) -> Pin<Box<dyn Future<Output = Result<AnyBytes, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
fn statistics<'life0, 'async_trait>(
&'life0 self,
header_hash: HeaderHash,
) -> Pin<Box<dyn Future<Output = Result<AnyBytes, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
Returns the activity statistics stored in the posterior state of the block with the given header hash.
The statistics are encoded as per the GP.
Sourcefn service_data<'life0, 'async_trait>(
&'life0 self,
header_hash: HeaderHash,
id: ServiceId,
) -> Pin<Box<dyn Future<Output = Result<Option<AnyBytes>, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
fn service_data<'life0, 'async_trait>(
&'life0 self,
header_hash: HeaderHash,
id: ServiceId,
) -> Pin<Box<dyn Future<Output = Result<Option<AnyBytes>, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
Returns the storage data for the service with the given ID.
The data are encoded as per the GP. None is returned if there is no service with the
given ID.
Sourcefn service_value<'life0, 'async_trait>(
&'life0 self,
header_hash: HeaderHash,
id: ServiceId,
key: AnyVec,
) -> Pin<Box<dyn Future<Output = Result<Option<AnyBytes>, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
fn service_value<'life0, 'async_trait>(
&'life0 self,
header_hash: HeaderHash,
id: ServiceId,
key: AnyVec,
) -> Pin<Box<dyn Future<Output = Result<Option<AnyBytes>, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
Returns the value associated with the given service ID and key in the posterior state of the block with the given header hash.
None is returned if there is no value associated with the given service ID and key.
This method can be used to query arbitrary key-value pairs set by service accumulation logic.
Sourcefn service_preimage<'life0, 'async_trait>(
&'life0 self,
header_hash: HeaderHash,
id: ServiceId,
hash: AnyHash,
) -> Pin<Box<dyn Future<Output = Result<Option<AnyBytes>, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
fn service_preimage<'life0, 'async_trait>(
&'life0 self,
header_hash: HeaderHash,
id: ServiceId,
hash: AnyHash,
) -> Pin<Box<dyn Future<Output = Result<Option<AnyBytes>, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
Returns the preimage of the given hash, if it has been provided to the given service in the posterior state of the block with the given header hash.
None is returned if the preimage has not been provided to the given service.
Sourcefn service_request<'life0, 'async_trait>(
&'life0 self,
header_hash: HeaderHash,
id: ServiceId,
hash: AnyHash,
len: u32,
) -> Pin<Box<dyn Future<Output = Result<Option<Vec<Slot>>, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
fn service_request<'life0, 'async_trait>(
&'life0 self,
header_hash: HeaderHash,
id: ServiceId,
hash: AnyHash,
len: u32,
) -> Pin<Box<dyn Future<Output = Result<Option<Vec<Slot>>, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
Returns the preimage request associated with the given service ID and hash/length in the posterior state of the block with the given header hash.
None is returned if the preimage with the given hash/length has neither been requested by
nor provided to the given service. An empty list is returned if the preimage has been
requested, but not yet provided. A non-empty list means that the preimage has been
provided; the meaning of the slots in the list is as follows:
- The first slot is the slot in which the preimage was provided.
- The second slot, if present, is the slot in which the preimage was “forgotten”.
- The third slot, if present, is the slot in which the preimage was requested again.
Sourcefn work_report<'life0, 'async_trait>(
&'life0 self,
hash: WorkReportHash,
) -> Pin<Box<dyn Future<Output = Result<AnyBytes, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
fn work_report<'life0, 'async_trait>(
&'life0 self,
hash: WorkReportHash,
) -> Pin<Box<dyn Future<Output = Result<AnyBytes, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
Returns the work-report with the given hash.
The work-report is encoded as per the GP.
Sourcefn submit_work_package<'life0, 'async_trait>(
&'life0 self,
core: CoreIndex,
package: AnyBytes,
extrinsics: Vec<AnyBytes>,
) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
fn submit_work_package<'life0, 'async_trait>(
&'life0 self,
core: CoreIndex,
package: AnyBytes,
extrinsics: Vec<AnyBytes>,
) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
Submit a work-package to the guarantors currently assigned to the given core.
Sourcefn submit_work_package_bundle<'life0, 'async_trait>(
&'life0 self,
core: CoreIndex,
bundle: AnyBytes,
) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
fn submit_work_package_bundle<'life0, 'async_trait>(
&'life0 self,
core: CoreIndex,
bundle: AnyBytes,
) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
Submit a work-package bundle to the guarantors currently assigned to the given core.
Sourcefn work_package_status<'life0, 'async_trait>(
&'life0 self,
header_hash: HeaderHash,
hash: WorkPackageHash,
anchor: HeaderHash,
) -> Pin<Box<dyn Future<Output = Result<WorkPackageStatus, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
fn work_package_status<'life0, 'async_trait>(
&'life0 self,
header_hash: HeaderHash,
hash: WorkPackageHash,
anchor: HeaderHash,
) -> Pin<Box<dyn Future<Output = Result<WorkPackageStatus, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
Returns the status of the given work-package following execution of the block with the given header hash.
If anchor does not match the anchor of the work-package then an error or an incorrect
status may be returned. An error may be returned if anchor is too old.
Sourcefn submit_preimage<'life0, 'async_trait>(
&'life0 self,
requester: ServiceId,
preimage: AnyBytes,
) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
fn submit_preimage<'life0, 'async_trait>(
&'life0 self,
requester: ServiceId,
preimage: AnyBytes,
) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
Submit a preimage which is being requested by the given service.
Note that this method does not wait for the preimage to be distributed or integrated on-chain; it returns immediately.
Sourcefn list_services<'life0, 'async_trait>(
&'life0 self,
header_hash: HeaderHash,
) -> Pin<Box<dyn Future<Output = Result<Vec<ServiceId>, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
fn list_services<'life0, 'async_trait>(
&'life0 self,
header_hash: HeaderHash,
) -> Pin<Box<dyn Future<Output = Result<Vec<ServiceId>, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
Returns a list of all services currently known to be on JAM.
This is a best-effort list and may not reflect the true state. Nodes could e.g. reasonably hide services which are not recently active from this list.
Sourcefn fetch_work_package_segments<'life0, 'async_trait>(
&'life0 self,
wp_hash: WorkPackageHash,
indices: Vec<u16>,
) -> Pin<Box<dyn Future<Output = Result<Vec<WrappedSegment>, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
fn fetch_work_package_segments<'life0, 'async_trait>(
&'life0 self,
wp_hash: WorkPackageHash,
indices: Vec<u16>,
) -> Pin<Box<dyn Future<Output = Result<Vec<WrappedSegment>, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
Fetches a list of segments from the DA layer, exported by the work-package with the given hash.
Sourcefn fetch_segments<'life0, 'async_trait>(
&'life0 self,
segment_root: SegmentTreeRoot,
indices: Vec<u16>,
) -> Pin<Box<dyn Future<Output = Result<Vec<WrappedSegment>, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
fn fetch_segments<'life0, 'async_trait>(
&'life0 self,
segment_root: SegmentTreeRoot,
indices: Vec<u16>,
) -> Pin<Box<dyn Future<Output = Result<Vec<WrappedSegment>, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
Fetches a list of segments from the DA layer, exported by a work-package with the given segment root hash.
Sourcefn sync_state<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<SyncState, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
fn sync_state<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<SyncState, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
Returns the sync status of the node.
Sourcefn subscribe_best_block<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Subscription<BlockDesc>, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
fn subscribe_best_block<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Subscription<BlockDesc>, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
Subscribe to updates of the head of the “best” chain, as returned by bestBlock.
Sourcefn subscribe_finalized_block<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Subscription<BlockDesc>, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
fn subscribe_finalized_block<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Subscription<BlockDesc>, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
Subscribe to updates of the latest finalized block, as returned by finalizedBlock.
Sourcefn subscribe_statistics<'life0, 'async_trait>(
&'life0 self,
finalized: bool,
) -> Pin<Box<dyn Future<Output = Result<Subscription<ChainSubUpdate<AnyBytes>>, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
fn subscribe_statistics<'life0, 'async_trait>(
&'life0 self,
finalized: bool,
) -> Pin<Box<dyn Future<Output = Result<Subscription<ChainSubUpdate<AnyBytes>>, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
Subscribe to updates of the activity statistics stored in chain state.
The statistics are encoded as per the GP.
Sourcefn subscribe_service_data<'life0, 'async_trait>(
&'life0 self,
id: ServiceId,
finalized: bool,
) -> Pin<Box<dyn Future<Output = Result<Subscription<ChainSubUpdate<Option<AnyBytes>>>, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
fn subscribe_service_data<'life0, 'async_trait>(
&'life0 self,
id: ServiceId,
finalized: bool,
) -> Pin<Box<dyn Future<Output = Result<Subscription<ChainSubUpdate<Option<AnyBytes>>>, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
Subscribe to updates of the storage data for the service with the given ID.
The value field of updates will contain service data encoded as per the GP. It will be
None when there is no service with the given ID.
Sourcefn subscribe_service_value<'life0, 'async_trait>(
&'life0 self,
id: ServiceId,
key: AnyVec,
finalized: bool,
) -> Pin<Box<dyn Future<Output = Result<Subscription<ChainSubUpdate<Option<AnyBytes>>>, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
fn subscribe_service_value<'life0, 'async_trait>(
&'life0 self,
id: ServiceId,
key: AnyVec,
finalized: bool,
) -> Pin<Box<dyn Future<Output = Result<Subscription<ChainSubUpdate<Option<AnyBytes>>>, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
Subscribe to updates of the value associated with the given service ID and key.
The value field of updates will be None when there is no value associated with the
given service ID and key.
Sourcefn subscribe_service_preimage<'life0, 'async_trait>(
&'life0 self,
id: ServiceId,
hash: AnyHash,
finalized: bool,
) -> Pin<Box<dyn Future<Output = Result<Subscription<ChainSubUpdate<Option<AnyBytes>>>, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
fn subscribe_service_preimage<'life0, 'async_trait>(
&'life0 self,
id: ServiceId,
hash: AnyHash,
finalized: bool,
) -> Pin<Box<dyn Future<Output = Result<Subscription<ChainSubUpdate<Option<AnyBytes>>>, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
Subscribe to updates of the preimage associated with the given service ID and hash.
The value field of updates will be None if the preimage has not been provided to the
service. Otherwise, it will be the preimage of the given hash.
Sourcefn subscribe_service_request<'life0, 'async_trait>(
&'life0 self,
id: ServiceId,
hash: AnyHash,
len: u32,
finalized: bool,
) -> Pin<Box<dyn Future<Output = Result<Subscription<ChainSubUpdate<Option<Vec<Slot>>>>, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
fn subscribe_service_request<'life0, 'async_trait>(
&'life0 self,
id: ServiceId,
hash: AnyHash,
len: u32,
finalized: bool,
) -> Pin<Box<dyn Future<Output = Result<Subscription<ChainSubUpdate<Option<Vec<Slot>>>>, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
Subscribe to updates of the preimage request associated with the given service ID and hash/length.
The value field of updates will either be None or a list of slots, with the same
semantics as serviceRequest return values.
Sourcefn subscribe_work_package_status<'life0, 'async_trait>(
&'life0 self,
hash: WorkPackageHash,
anchor: HeaderHash,
finalized: bool,
) -> Pin<Box<dyn Future<Output = Result<Subscription<ChainSubUpdate<WorkPackageStatus>>, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
fn subscribe_work_package_status<'life0, 'async_trait>(
&'life0 self,
hash: WorkPackageHash,
anchor: HeaderHash,
finalized: bool,
) -> Pin<Box<dyn Future<Output = Result<Subscription<ChainSubUpdate<WorkPackageStatus>>, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
Subscribe to status updates for the given work-package.
If anchor does not match the anchor of the work-package then the subscription may fail or
yield incorrect statuses. The subscription may fail if anchor is too old.
Sourcefn subscribe_sync_status<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Subscription<SyncStatus>, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
fn subscribe_sync_status<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Subscription<SyncStatus>, Error>> + Send + 'async_trait>>where
Self: Sync + 'async_trait,
'life0: 'async_trait,
Subscribe to changes in sync status.
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.