pub struct RetryLimit(/* private fields */);Expand description
The maximum number of re-invocations after the initial component call.
Implementations§
Source§impl RetryLimit
impl RetryLimit
Sourcepub fn new(value: u32) -> Result<Self, FaultPolicyError>
pub fn new(value: u32) -> Result<Self, FaultPolicyError>
Validates and constructs a bounded retry limit.
§Errors
Returns FaultPolicyError::RetryLimitOutOfRange above 65,535.
Sourcepub const fn permits(self, ordinal: RetryOrdinal) -> bool
pub const fn permits(self, ordinal: RetryOrdinal) -> bool
Returns whether ordinal may still be reserved.
The initial call is not a retry, so it is never permitted here.
Trait Implementations§
Source§impl Clone for RetryLimit
impl Clone for RetryLimit
impl Copy for RetryLimit
Source§impl Debug for RetryLimit
impl Debug for RetryLimit
Source§impl Default for RetryLimit
impl Default for RetryLimit
impl Eq for RetryLimit
Source§impl Hash for RetryLimit
impl Hash for RetryLimit
Source§impl Ord for RetryLimit
impl Ord for RetryLimit
1.21.0 (const: unstable) · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
1.21.0 (const: unstable) · Source§fn min(self, other: Self) -> Selfwhere
Self: Sized,
fn min(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the minimum of two values. Read more
Source§impl PartialEq for RetryLimit
impl PartialEq for RetryLimit
Source§impl PartialOrd for RetryLimit
impl PartialOrd for RetryLimit
impl StructuralPartialEq for RetryLimit
Auto Trait Implementations§
impl Freeze for RetryLimit
impl RefUnwindSafe for RetryLimit
impl Send for RetryLimit
impl Sync for RetryLimit
impl Unpin for RetryLimit
impl UnsafeUnpin for RetryLimit
impl UnwindSafe for RetryLimit
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