pub trait Contiguous: Send + Sync {
type Item;
// Required methods
fn reader(
&self,
) -> impl Future<Output = impl Reader<Item = Self::Item> + '_> + Send;
fn size(&self) -> impl Future<Output = u64> + Send;
}Expand description
Journals that support sequential append operations.
Maintains a monotonically increasing position counter where each appended item receives a unique position starting from 0.
Required Associated Types§
Required Methods§
Sourcefn reader(
&self,
) -> impl Future<Output = impl Reader<Item = Self::Item> + '_> + Send
fn reader( &self, ) -> impl Future<Output = impl Reader<Item = Self::Item> + '_> + Send
Acquire a reader guard that holds a consistent view of the journal.
While the returned guard exists, operations that need the journal’s
internal write lock (such as append, prune, and rewind) may block
until the guard is dropped. This ensures any position within
reader.bounds() remains readable.
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.