Struct EnteredSpan
#[must_use = "once a span has been entered, it should be exited"]
pub struct EnteredSpan { /* private fields */ }
An owned version of Entered, a guard representing a span which has been
entered and is currently executing.
When the guard is dropped, the span will be exited.
This is returned by the Span::entered function.
Implementations
impl EnteredSpan
fn id(&self) -> Option<Id>Returns this span's
Id, if it is enabled.fn exit(self) -> SpanExits this span, returning the underlying
Span.
Trait Implementations
impl Debug for EnteredSpan
fn fmt(&self, f: &mut Formatter<'_>) -> Result
impl Deref for EnteredSpan
type Target = Span;fn deref(&self) -> &Span
impl Drop for EnteredSpan
fn drop(&mut self)
Auto Trait Implementations
impl !RefUnwindSafe for EnteredSpan
impl !Send for EnteredSpan
impl !UnwindSafe for EnteredSpan
impl Freeze for EnteredSpan
impl Sync for EnteredSpan
impl Unpin for EnteredSpan
impl UnsafeUnpin for EnteredSpan
Blanket Implementations
impl<P, T> Receiver for EnteredSpan
where
P: Deref<Target = T> + ?Sized,
T: ?Sized,
type Target = T;
impl<T> Any for EnteredSpan
where
T: 'static + ?Sized,
fn type_id(&self) -> TypeId
impl<T> Borrow<T> for EnteredSpan
where
T: ?Sized,
fn borrow(&self) -> &T
impl<T> BorrowMut<T> for EnteredSpan
where
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
impl<T> From<T> for EnteredSpan
fn from(t: T) -> TReturns the argument unchanged.
impl<T> Instrument for EnteredSpan
impl<T> WithSubscriber for EnteredSpan
impl<T, U> Into<U> for EnteredSpan
where
U: From<T>,
fn into(self) -> UCalls
U::from(self).That is, this conversion is whatever the implementation of
[From]<T> for Uchooses to do.
impl<T, U> TryFrom<U> for EnteredSpan
where
U: Into<T>,
type Error = Infallible;fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
impl<T, U> TryInto<U> for EnteredSpan
where
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error;fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>