pub struct DerivedCursor { /* private fields */ }Expand description
Exclusive CommitLog position durably completed by one derived engine.
Implementations§
Source§impl DerivedCursor
impl DerivedCursor
Sourcepub const fn genesis(source_epoch: u64) -> Self
pub const fn genesis(source_epoch: u64) -> Self
Creates the initial cursor for one CommitLog source epoch.
Sourcepub const fn restore(source_epoch: u64, next_offset: u64) -> Self
pub const fn restore(source_epoch: u64, next_offset: u64) -> Self
Restores a cursor whose next record starts at next_offset.
Sourcepub const fn source_epoch(self) -> u64
pub const fn source_epoch(self) -> u64
Returns the source generation that owns this offset namespace.
Sourcepub const fn next_offset(self) -> u64
pub const fn next_offset(self) -> u64
Returns the exclusive durable cursor and next expected record offset.
Sourcepub const fn prepare(
self,
record: DerivedRecordId,
) -> Result<CursorAdvanceDisposition, StoreContractViolation>
pub const fn prepare( self, record: DerivedRecordId, ) -> Result<CursorAdvanceDisposition, StoreContractViolation>
Classifies a replayed record without mutating or persisting this cursor.
§Errors
Returns StoreContractViolation for a different source epoch, a physical gap, or a record
that only partially overlaps the committed prefix.
Trait Implementations§
Source§impl Clone for DerivedCursor
impl Clone for DerivedCursor
impl Copy for DerivedCursor
Source§impl Debug for DerivedCursor
impl Debug for DerivedCursor
impl Eq for DerivedCursor
Source§impl Hash for DerivedCursor
impl Hash for DerivedCursor
Source§impl PartialEq for DerivedCursor
impl PartialEq for DerivedCursor
impl StructuralPartialEq for DerivedCursor
Auto Trait Implementations§
impl Freeze for DerivedCursor
impl RefUnwindSafe for DerivedCursor
impl Send for DerivedCursor
impl Sync for DerivedCursor
impl Unpin for DerivedCursor
impl UnsafeUnpin for DerivedCursor
impl UnwindSafe for DerivedCursor
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more