Trait StoreDirectory

Source
pub trait StoreDirectory {
    type Entry;
    type Reader: StoreDirectoryReader<Self::Entry>;

    // Required methods
    fn exists(&self) -> impl Future<Output = Result<bool>>;
    fn read(&self) -> impl Future<Output = Result<Self::Reader>>;
}
Expand description

Trait representing a directory in the storage system.

Required Associated Types§

Source

type Entry

Associated type for entries in the directory.

Source

type Reader: StoreDirectoryReader<Self::Entry>

Associated type for the reader that iterates over the directory’s entries.

Required Methods§

Source

fn exists(&self) -> impl Future<Output = Result<bool>>

Checks if the directory exists.

Returns a future that resolves to true if the directory exists, otherwise false.

Source

fn read(&self) -> impl Future<Output = Result<Self::Reader>>

Reads the contents of the directory.

Returns a future that resolves to a reader for the directory’s entries.

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.

Implementors§