Trait AvailabilityApi
Source pub trait AvailabilityApi {
type NamespaceProofQueryData: Serialize + Send + Sync + 'static;
type IncorrectEncodingProof: Serialize + Send + Sync;
type StateCertQueryDataV1: Serialize + Send + Sync;
type StateCertQueryDataV2: Serialize + Send + Sync;
// Required methods
fn get_namespace_proof<'life0, 'async_trait>(
&'life0 self,
block_id: BlockId,
namespace: u32,
) -> Pin<Box<dyn Future<Output = Result<Option<Self::NamespaceProofQueryData>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn get_namespace_proof_range<'life0, 'async_trait>(
&'life0 self,
from: u64,
until: u64,
namespace: u32,
) -> Pin<Box<dyn Future<Output = Result<Vec<Self::NamespaceProofQueryData>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn stream_namespace_proofs<'life0, 'async_trait>(
&'life0 self,
from: usize,
namespace: u32,
) -> Pin<Box<dyn Future<Output = Result<BoxStream<'static, Self::NamespaceProofQueryData>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn get_incorrect_encoding_proof<'life0, 'async_trait>(
&'life0 self,
block_id: BlockId,
namespace: u32,
) -> Pin<Box<dyn Future<Output = Result<Self::IncorrectEncodingProof>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn get_state_cert<'life0, 'async_trait>(
&'life0 self,
epoch: u64,
) -> Pin<Box<dyn Future<Output = Result<Self::StateCertQueryDataV1>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn get_state_cert_v2<'life0, 'async_trait>(
&'life0 self,
epoch: u64,
) -> Pin<Box<dyn Future<Output = Result<Self::StateCertQueryDataV2>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
}