pub struct PendingDiagnosticState { /* private fields */ }Expand description
Pending reports retained by one work owner between synchronous slices. The value may move between workers; an installed scope cannot. Starting a state neither adopts ambient reports nor drains router processor logs.
Implementations§
Source§impl PendingDiagnosticState
impl PendingDiagnosticState
pub fn new() -> Self
Sourcepub fn adopt_current_mapped(&mut self)
pub fn adopt_current_mapped(&mut self)
Deliberately adopt only the legacy pending-mapped CSG channel at owner admission. Curve/face reports already pending for the caller stay ambient. Call once at the owning executor’s first live admission, not planning.
Sourcepub fn with_scope<T>(&mut self, work: impl FnOnce() -> T) -> T
pub fn with_scope<T>(&mut self, work: impl FnOnce() -> T) -> T
Install owner reports, retain new leftovers on return/error/unwind, and restore the caller’s pending reports exactly. No scope crosses a yield. Work that drains reports through its ordinary router still does so here; this primitive does not introduce a per-poll processor drain.
Sourcepub fn publish_pending(&mut self)
pub fn publish_pending(&mut self)
Publish this owner’s remaining reports once at its validated terminal boundary. The caller chooses success/error/cancellation delivery policy; dropping a state never silently publishes it into another owner’s TLS. Existing caller face ordering and mapped-record prefixes are retained.
Trait Implementations§
Source§impl Debug for PendingDiagnosticState
impl Debug for PendingDiagnosticState
Source§impl Default for PendingDiagnosticState
impl Default for PendingDiagnosticState
Source§fn default() -> PendingDiagnosticState
fn default() -> PendingDiagnosticState
Auto Trait Implementations§
impl Freeze for PendingDiagnosticState
impl RefUnwindSafe for PendingDiagnosticState
impl Send for PendingDiagnosticState
impl Sync for PendingDiagnosticState
impl Unpin for PendingDiagnosticState
impl UnwindSafe for PendingDiagnosticState
Blanket Implementations§
§impl<U> As for U
impl<U> As for U
§fn as_<T>(self) -> Twhere
T: CastFrom<U>,
fn as_<T>(self) -> Twhere
T: CastFrom<U>,
self to type T. The semantics of numeric casting with the as operator are followed, so <T as As>::as_::<U> can be used in the same way as T as U for numeric conversions. Read moreSource§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
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more§impl<T> Pointable for T
impl<T> Pointable for T
§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
§fn to_subset(&self) -> Option<SS>
fn to_subset(&self) -> Option<SS>
self from the equivalent element of its
superset. Read more§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
self is actually part of its subset T (and can be converted to it).§fn to_subset_unchecked(&self) -> SS
fn to_subset_unchecked(&self) -> SS
self.to_subset but without any property checks. Always succeeds.§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
self to the equivalent element of its superset.