pub struct OperationBound(/* private fields */);Expand description
One elapsed-time authority for a concrete runtime operation.
The finite form retains only its start and total budget. Consumers can observe the remaining interval or derive a capped attempt, but cannot recover a duration from which to restart the operation clock.
Implementations§
Source§impl OperationBound
impl OperationBound
pub fn finite(budget: Duration) -> Self
pub fn unbounded() -> Self
pub fn remaining(&self) -> Remaining
pub fn attempt(&self, cap: Option<Duration>) -> AttemptBound
pub fn is_expired(&self) -> bool
pub fn elapsed_ms(&self) -> u64
pub fn timing( &self, start_boundary: &str, terminal_cause: OperationTerminalCause, ) -> OperationTimingEvidence
Auto Trait Implementations§
impl Freeze for OperationBound
impl RefUnwindSafe for OperationBound
impl Send for OperationBound
impl Sync for OperationBound
impl Unpin for OperationBound
impl UnsafeUnpin for OperationBound
impl UnwindSafe for OperationBound
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