Enum slog_async::OverflowStrategy
source · pub enum OverflowStrategy {
DropAndReport,
Drop,
Block,
// some variants omitted
}
Expand description
Behavior used when the channel is full.
Note
More variants may be added in the future, without considering it a breaking change.
Variants§
DropAndReport
The message gets dropped and a message with number of dropped is produced once there’s space.
This is the default.
Note that the message with number of dropped messages takes one slot in the channel as well.
Drop
The message gets dropped silently.
Block
The caller is blocked until there’s enough space.
Trait Implementations§
source§impl Clone for OverflowStrategy
impl Clone for OverflowStrategy
source§fn clone(&self) -> OverflowStrategy
fn clone(&self) -> OverflowStrategy
Returns a copy 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 OverflowStrategy
impl Debug for OverflowStrategy
source§impl Hash for OverflowStrategy
impl Hash for OverflowStrategy
source§impl Ord for OverflowStrategy
impl Ord for OverflowStrategy
source§fn cmp(&self, other: &OverflowStrategy) -> Ordering
fn cmp(&self, other: &OverflowStrategy) -> Ordering
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere Self: Sized,
Compares and returns the maximum of two values. Read more
source§impl PartialEq<OverflowStrategy> for OverflowStrategy
impl PartialEq<OverflowStrategy> for OverflowStrategy
source§fn eq(&self, other: &OverflowStrategy) -> bool
fn eq(&self, other: &OverflowStrategy) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl PartialOrd<OverflowStrategy> for OverflowStrategy
impl PartialOrd<OverflowStrategy> for OverflowStrategy
source§fn partial_cmp(&self, other: &OverflowStrategy) -> Option<Ordering>
fn partial_cmp(&self, other: &OverflowStrategy) -> Option<Ordering>
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self
and other
) and is used by the <=
operator. Read moreimpl Copy for OverflowStrategy
impl Eq for OverflowStrategy
impl StructuralEq for OverflowStrategy
impl StructuralPartialEq for OverflowStrategy
Auto Trait Implementations§
impl RefUnwindSafe for OverflowStrategy
impl Send for OverflowStrategy
impl Sync for OverflowStrategy
impl Unpin for OverflowStrategy
impl UnwindSafe for OverflowStrategy
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