pub enum PushResult {
Added,
Duplicate,
Evicted([u8; 32]),
DroppedZeroCapacity([u8; 32]),
}Expand description
Result of pushing a delta to the buffer.
Provides clear semantics about what happened to both the incoming delta and any evicted delta.
Variants§
Added
Delta was added to the buffer without eviction.
Duplicate
Delta was a duplicate (already in buffer) - no action taken.
Evicted([u8; 32])
Delta was added, but oldest delta was evicted due to capacity. Contains the ID of the evicted delta.
DroppedZeroCapacity([u8; 32])
Delta was dropped immediately (zero capacity buffer). Contains the ID of the dropped delta.
Implementations§
Source§impl PushResult
impl PushResult
Trait Implementations§
Source§impl Clone for PushResult
impl Clone for PushResult
Source§fn clone(&self) -> PushResult
fn clone(&self) -> PushResult
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for PushResult
impl Debug for PushResult
Source§impl PartialEq for PushResult
impl PartialEq for PushResult
impl Eq for PushResult
impl StructuralPartialEq for PushResult
Auto Trait Implementations§
impl Freeze for PushResult
impl RefUnwindSafe for PushResult
impl Send for PushResult
impl Sync for PushResult
impl Unpin for PushResult
impl UnsafeUnpin for PushResult
impl UnwindSafe for PushResult
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more