Skip to main content

ChunkHas

Trait ChunkHas 

Source
pub trait ChunkHas<const BODY_SIZE: usize = DEFAULT_BODY_SIZE>: MaybeSend + MaybeSync {
    // Required method
    fn has(
        &self,
        address: &ChunkAddress,
    ) -> impl Future<Output = bool> + MaybeSend;
}
Expand description

Async chunk existence check (primary API).

Required Methods§

Source

fn has(&self, address: &ChunkAddress) -> impl Future<Output = bool> + MaybeSend

Check if a chunk exists.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementations on Foreign Types§

Source§

impl<T: ChunkHas<BS> + ?Sized, const BS: usize> ChunkHas<BS> for &T

Source§

fn has(&self, address: &ChunkAddress) -> impl Future<Output = bool> + MaybeSend

Source§

impl<const BODY_SIZE: usize> ChunkHas<BODY_SIZE> for HashMap<ChunkAddress, AnyChunk<BODY_SIZE>>

Source§

async fn has(&self, address: &ChunkAddress) -> bool

Implementors§

Source§

impl<const BODY_SIZE: usize> ChunkHas<BODY_SIZE> for MemoryStore<BODY_SIZE>