pub struct Not<A, S> { /* private fields */ }
Available on crate features
registry
and std
only.Expand description
Inverts the result of a Filter
.
If the wrapped filter would enable a span or event, it will be disabled. If it would disable a span or event, that span or event will be enabled.
This type is typically returned by the FilterExt::not
method. See that
method’s documentation for details.
Trait Implementations§
Source§impl<A, S> Filter<S> for Not<A, S>where
A: Filter<S>,
impl<A, S> Filter<S> for Not<A, S>where
A: Filter<S>,
Source§fn enabled(&self, meta: &Metadata<'_>, cx: &Context<'_, S>) -> bool
fn enabled(&self, meta: &Metadata<'_>, cx: &Context<'_, S>) -> bool
Returns
true
if this layer is interested in a span or event with the
given Metadata
in the current Context
, similarly to
Subscriber::enabled
. Read moreSource§fn callsite_enabled(&self, meta: &'static Metadata<'static>) -> Interest
fn callsite_enabled(&self, meta: &'static Metadata<'static>) -> Interest
Source§fn max_level_hint(&self) -> Option<LevelFilter> ⓘ
fn max_level_hint(&self) -> Option<LevelFilter> ⓘ
Source§fn event_enabled(&self, event: &Event<'_>, cx: &Context<'_, S>) -> bool
fn event_enabled(&self, event: &Event<'_>, cx: &Context<'_, S>) -> bool
Called before the filtered [
Layer]'s [
on_event], to determine if
on_event` should be called. Read moreSource§fn on_new_span(&self, attrs: &Attributes<'_>, id: &Id, ctx: Context<'_, S>)
fn on_new_span(&self, attrs: &Attributes<'_>, id: &Id, ctx: Context<'_, S>)
Source§fn on_enter(&self, id: &Id, ctx: Context<'_, S>)
fn on_enter(&self, id: &Id, ctx: Context<'_, S>)
Notifies this filter that a span with the given ID was entered. Read more
Auto Trait Implementations§
impl<A, S> Freeze for Not<A, S>where
A: Freeze,
impl<A, S> RefUnwindSafe for Not<A, S>where
A: RefUnwindSafe,
impl<A, S> Send for Not<A, S>where
A: Send,
impl<A, S> Sync for Not<A, S>where
A: Sync,
impl<A, S> Unpin for Not<A, S>where
A: Unpin,
impl<A, S> UnwindSafe for Not<A, S>where
A: 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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<F, S> FilterExt<S> for Fwhere
F: Filter<S>,
impl<F, S> FilterExt<S> for Fwhere
F: Filter<S>,
Source§fn and<B>(self, other: B) -> And<Self, B, S> ⓘ
fn and<B>(self, other: B) -> And<Self, B, S> ⓘ
Available on crate features
registry
and std
only.Source§fn or<B>(self, other: B) -> Or<Self, B, S> ⓘ
fn or<B>(self, other: B) -> Or<Self, B, S> ⓘ
Available on crate features
registry
and std
only.