#[non_exhaustive]pub enum WindowKind {
Disjoint,
Sliding(SlidingWindow),
}Expand description
How batches are formed over an input stream.
The window policy controls how items from a stream are grouped into Windows.
WindowKind::Disjoint(default): non-overlapping windows; each window consumessizeitems from the stream and the next window begins immediately after.WindowKind::Sliding: fixed-size windows that advance by a fixed step. Each produced window containssizeitems, and the next window startsstrideitems after the previous window start. Whenstride == size, this is equivalent toWindowKind::Disjoint.
For WindowKind::Sliding, stride <= size is expected.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Disjoint
Non-overlapping (disjoint) windows; default.
Sliding(SlidingWindow)
Sliding windows: each produced window has size items and windows advance
by stride items between steps.
Trait Implementations§
Source§impl Clone for WindowKind
impl Clone for WindowKind
Source§fn clone(&self) -> WindowKind
fn clone(&self) -> WindowKind
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 WindowKind
impl Debug for WindowKind
Source§impl PartialEq for WindowKind
impl PartialEq for WindowKind
impl Copy for WindowKind
impl Eq for WindowKind
impl StructuralPartialEq for WindowKind
Auto Trait Implementations§
impl Freeze for WindowKind
impl RefUnwindSafe for WindowKind
impl Send for WindowKind
impl Sync for WindowKind
impl Unpin for WindowKind
impl UnsafeUnpin for WindowKind
impl UnwindSafe for WindowKind
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