pub struct TimerCadence(/* private fields */);Expand description
Validated positive recurrence cadence.
Implementations§
Source§impl TimerCadence
impl TimerCadence
Sourcepub fn new(cadence: Duration) -> Result<Self, ScheduleError>
pub fn new(cadence: Duration) -> Result<Self, ScheduleError>
Validate a recurrence cadence.
Sourcepub const fn from_nanos(cadence_ns: u64) -> Result<Self, ScheduleError>
pub const fn from_nanos(cadence_ns: u64) -> Result<Self, ScheduleError>
Validate an already encoded nanosecond cadence.
Trait Implementations§
Source§impl Clone for TimerCadence
impl Clone for TimerCadence
Source§fn clone(&self) -> TimerCadence
fn clone(&self) -> TimerCadence
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for TimerCadence
Source§impl Debug for TimerCadence
impl Debug for TimerCadence
impl Eq for TimerCadence
Source§impl Hash for TimerCadence
impl Hash for TimerCadence
Source§impl Ord for TimerCadence
impl Ord for TimerCadence
Source§fn cmp(&self, other: &TimerCadence) -> Ordering
fn cmp(&self, other: &TimerCadence) -> Ordering
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
Source§impl PartialEq for TimerCadence
impl PartialEq for TimerCadence
Source§impl PartialOrd for TimerCadence
impl PartialOrd for TimerCadence
impl StructuralPartialEq for TimerCadence
Auto Trait Implementations§
impl Freeze for TimerCadence
impl RefUnwindSafe for TimerCadence
impl Send for TimerCadence
impl Sync for TimerCadence
impl Unpin for TimerCadence
impl UnsafeUnpin for TimerCadence
impl UnwindSafe for TimerCadence
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