pub struct EventScope { /* private fields */ }Expand description
One thread-bound nested attempt. It retains scalar labels only. End and transition methods borrow immutably, allowing use inside native callbacks.
Implementations§
Source§impl EventScope
impl EventScope
Sourcepub fn begin(stage: u32, ordinal: u64, root: RootIdentity) -> Self
pub fn begin(stage: u32, ordinal: u64, root: RootIdentity) -> Self
Publish an explicit entry, or return an inert guard when no sink is active. The ordinal is caller metadata; each attempt receives a separate span ID.
Sourcepub fn transition(&self, stage: u32)
pub fn transition(&self, stage: u32)
Publish entry into the next stage. This labels subsequent work, not the interval just completed. A noncurrent scope disables telemetry.
Trait Implementations§
Source§impl Drop for EventScope
impl Drop for EventScope
Auto Trait Implementations§
impl !Freeze for EventScope
impl !RefUnwindSafe for EventScope
impl !Send for EventScope
impl !Sync for EventScope
impl Forget for EventScope
impl Move for EventScope
impl Unpin for EventScope
impl UnsafeUnpin for EventScope
impl UnwindSafe for EventScope
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