pub enum LateDataResult<T> {
OnTime(T),
WithinLateness(T),
Drop,
SideOutput(T),
}Expand description
Result of evaluating whether an element is late.
Variants§
OnTime(T)
The element is not late and should be processed normally.
WithinLateness(T)
The element is late but within allowed lateness.
Drop
The element is late and should be dropped.
SideOutput(T)
The element is late and should be redirected to side output.
Implementations§
Source§impl<T> LateDataResult<T>
impl<T> LateDataResult<T>
Sourcepub fn should_process(&self) -> bool
pub fn should_process(&self) -> bool
Returns true if the element should be processed (OnTime or WithinLateness).
Sourcepub fn into_processable(self) -> Option<T>
pub fn into_processable(self) -> Option<T>
Extracts the element if it should be processed.
Sourcepub fn is_side_output(&self) -> bool
pub fn is_side_output(&self) -> bool
Returns true if this is a side output.
Sourcepub fn into_side_output(self) -> Option<T>
pub fn into_side_output(self) -> Option<T>
Extracts the element for side output.
Trait Implementations§
Source§impl<T: Clone> Clone for LateDataResult<T>
impl<T: Clone> Clone for LateDataResult<T>
Source§fn clone(&self) -> LateDataResult<T>
fn clone(&self) -> LateDataResult<T>
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<T: Debug> Debug for LateDataResult<T>
impl<T: Debug> Debug for LateDataResult<T>
Source§impl<T: PartialEq> PartialEq for LateDataResult<T>
impl<T: PartialEq> PartialEq for LateDataResult<T>
impl<T: Eq> Eq for LateDataResult<T>
impl<T> StructuralPartialEq for LateDataResult<T>
Auto Trait Implementations§
impl<T> Freeze for LateDataResult<T>where
T: Freeze,
impl<T> RefUnwindSafe for LateDataResult<T>where
T: RefUnwindSafe,
impl<T> Send for LateDataResult<T>where
T: Send,
impl<T> Sync for LateDataResult<T>where
T: Sync,
impl<T> Unpin for LateDataResult<T>where
T: Unpin,
impl<T> UnwindSafe for LateDataResult<T>where
T: UnwindSafe,
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