pub struct DeltaSub;Expand description
Rolling sum from cumulative: cum[h] - cum[start - 1]
Trait Implementations§
Source§impl<T> DeltaOp<T, T> for DeltaSubwhere
T: CheckedSub + Default,
impl<T> DeltaOp<T, T> for DeltaSubwhere
T: CheckedSub + Default,
Source§fn ago_index(start: usize) -> Option<usize>
fn ago_index(start: usize) -> Option<usize>
Source index for the
ago value given a window start.
Returns None when there is no preceding element (cumulative ops at start = 0).Source§fn ago_default() -> T
fn ago_default() -> T
Fallback
ago value when ago_index returns None.Source§fn count(h: usize, start: usize) -> usize
fn count(h: usize, start: usize) -> usize
Window element count from current index
h and window start.fn combine(current: T, ago: T, _count: usize) -> T
impl Copy for DeltaSub
Auto Trait Implementations§
impl Freeze for DeltaSub
impl RefUnwindSafe for DeltaSub
impl Send for DeltaSub
impl Sync for DeltaSub
impl Unpin for DeltaSub
impl UnsafeUnpin for DeltaSub
impl UnwindSafe for DeltaSub
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