pub enum WindowConfig {
CountBased(CountBasedWindowConfig),
TimeBased(TimeBasedWindowConfig),
}Expand description
滑动窗口配置枚举。
CountBased— 基于调用次数的滑动窗口TimeBased— 基于时间跨度的滑动窗口
Variants§
CountBased(CountBasedWindowConfig)
基于调用次数的滑动窗口(携带 CountBasedWindowConfig)
TimeBased(TimeBasedWindowConfig)
基于时间跨度的滑动窗口(携带 TimeBasedWindowConfig)
Trait Implementations§
Source§impl Clone for WindowConfig
impl Clone for WindowConfig
Source§fn clone(&self) -> WindowConfig
fn clone(&self) -> WindowConfig
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · 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 WindowConfig
impl Debug for WindowConfig
Source§impl Default for WindowConfig
impl Default for WindowConfig
Source§impl From<CountBasedWindowConfig> for WindowConfig
impl From<CountBasedWindowConfig> for WindowConfig
Source§fn from(cfg: CountBasedWindowConfig) -> Self
fn from(cfg: CountBasedWindowConfig) -> Self
Converts to this type from the input type.
Source§impl From<TimeBasedWindowConfig> for WindowConfig
impl From<TimeBasedWindowConfig> for WindowConfig
Source§fn from(cfg: TimeBasedWindowConfig) -> Self
fn from(cfg: TimeBasedWindowConfig) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for WindowConfig
impl RefUnwindSafe for WindowConfig
impl Send for WindowConfig
impl Sync for WindowConfig
impl Unpin for WindowConfig
impl UnsafeUnpin for WindowConfig
impl UnwindSafe for WindowConfig
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