pub struct SnapshotDelta {
pub delta: i64,
pub regression: bool,
}Expand description
The result of converting a cumulative snapshot into an incremental delta.
delta is always >= 0. If the snapshot regressed (new total < stored total),
delta is clamped to 0 and regression is set to true.
Fields§
§delta: i64Non-negative increment to add to the stored total.
regression: booltrue when the snapshot total was less than the stored total.
Trait Implementations§
Source§impl Clone for SnapshotDelta
impl Clone for SnapshotDelta
Source§fn clone(&self) -> SnapshotDelta
fn clone(&self) -> SnapshotDelta
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 SnapshotDelta
impl Debug for SnapshotDelta
Source§impl PartialEq for SnapshotDelta
impl PartialEq for SnapshotDelta
impl Copy for SnapshotDelta
impl Eq for SnapshotDelta
impl StructuralPartialEq for SnapshotDelta
Auto Trait Implementations§
impl Freeze for SnapshotDelta
impl RefUnwindSafe for SnapshotDelta
impl Send for SnapshotDelta
impl Sync for SnapshotDelta
impl Unpin for SnapshotDelta
impl UnsafeUnpin for SnapshotDelta
impl UnwindSafe for SnapshotDelta
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<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