pub struct OrSampler<A, B>(/* private fields */);Expand description
or combinator.
Trait Implementations§
Source§impl<A, B, T> Sampler<T> for OrSampler<A, B>
impl<A, B, T> Sampler<T> for OrSampler<A, B>
Source§fn is_sampled(&self, span: &CandidateSpan<'_, T>) -> bool
fn is_sampled(&self, span: &CandidateSpan<'_, T>) -> bool
This method decides whether a trace with given
span should be sampled.Source§fn or<U>(self, other: U) -> OrSampler<Self, U>
fn or<U>(self, other: U) -> OrSampler<Self, U>
Returns the sampler that samples a trace if
self or other decides to sample it.Source§fn and<U>(self, other: U) -> AndSampler<Self, U>
fn and<U>(self, other: U) -> AndSampler<Self, U>
Returns the sampler that samples a trace if both of
self and other decides to sample it.Auto Trait Implementations§
impl<A, B> Freeze for OrSampler<A, B>
impl<A, B> RefUnwindSafe for OrSampler<A, B>where
A: RefUnwindSafe,
B: RefUnwindSafe,
impl<A, B> Send for OrSampler<A, B>
impl<A, B> Sync for OrSampler<A, B>
impl<A, B> Unpin for OrSampler<A, B>
impl<A, B> UnwindSafe for OrSampler<A, B>where
A: UnwindSafe,
B: 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