#[non_exhaustive]pub struct ThresholdContext {
pub key_name: String,
pub failures_in_window: u32,
pub window: Duration,
pub lockout_triggered: bool,
}Expand description
Context for a configured threshold being crossed (e.g. N failures in M seconds).
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.key_name: StringLogical name of the key.
failures_in_window: u32Number of failures observed within the configured window.
window: DurationWidth of the configured window.
lockout_triggered: booltrue if this breach has put the vault into lock-out state.
Trait Implementations§
Source§impl Clone for ThresholdContext
impl Clone for ThresholdContext
Source§fn clone(&self) -> ThresholdContext
fn clone(&self) -> ThresholdContext
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 moreAuto Trait Implementations§
impl Freeze for ThresholdContext
impl RefUnwindSafe for ThresholdContext
impl Send for ThresholdContext
impl Sync for ThresholdContext
impl Unpin for ThresholdContext
impl UnsafeUnpin for ThresholdContext
impl UnwindSafe for ThresholdContext
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