pub enum PeriodicTaskTime {
Absolute(TimerExpMode<AbsoluteTime>),
Relative(TimerExpMode<RelativeTime>),
}Expand description
Programs the taks’s timer to specific time and mode. This instance is a wrapper around the TimerExpMode as this struct requers the generic to be specified which defines the type of the time.
Variants§
Absolute(TimerExpMode<AbsoluteTime>)
A provided time is absolute time in future.
Relative(TimerExpMode<RelativeTime>)
A provided time is relative to current time.
Implementations§
Source§impl PeriodicTaskTime
impl PeriodicTaskTime
Sourcepub fn exact_time(abs_time: AbsoluteTime) -> Self
pub fn exact_time(abs_time: AbsoluteTime) -> Self
The timer is set to time up once and for the specific absolute time in future
(to current realclock time).
Sourcepub fn interval(rel_time: RelativeTime) -> Self
pub fn interval(rel_time: RelativeTime) -> Self
The timer is set to time up in the interval for the relative time.
Sourcepub fn interval_with_start_delay(
start_del_time: RelativeTime,
rel_int_time: RelativeTime,
) -> Self
pub fn interval_with_start_delay( start_del_time: RelativeTime, rel_int_time: RelativeTime, ) -> Self
The timer is set to time up in the interval for the relative time with the initial
delay.
§Arguments
-
start_del_time- a RelativeTime of the initial delay. -
rel_int_time- a RelativeTime of the interval.
Trait Implementations§
Source§impl Clone for PeriodicTaskTime
impl Clone for PeriodicTaskTime
Source§fn clone(&self) -> PeriodicTaskTime
fn clone(&self) -> PeriodicTaskTime
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for PeriodicTaskTime
impl Debug for PeriodicTaskTime
Source§impl Display for PeriodicTaskTime
impl Display for PeriodicTaskTime
Source§impl From<TimerExpMode<AbsoluteTime>> for PeriodicTaskTime
impl From<TimerExpMode<AbsoluteTime>> for PeriodicTaskTime
Source§fn from(value: TimerExpMode<AbsoluteTime>) -> Self
fn from(value: TimerExpMode<AbsoluteTime>) -> Self
Converts to this type from the input type.
Source§impl From<TimerExpMode<RelativeTime>> for PeriodicTaskTime
impl From<TimerExpMode<RelativeTime>> for PeriodicTaskTime
Source§fn from(value: TimerExpMode<RelativeTime>) -> Self
fn from(value: TimerExpMode<RelativeTime>) -> Self
Converts to this type from the input type.
Source§impl PartialEq for PeriodicTaskTime
impl PartialEq for PeriodicTaskTime
impl Copy for PeriodicTaskTime
impl Eq for PeriodicTaskTime
impl StructuralPartialEq for PeriodicTaskTime
Auto Trait Implementations§
impl Freeze for PeriodicTaskTime
impl RefUnwindSafe for PeriodicTaskTime
impl Send for PeriodicTaskTime
impl Sync for PeriodicTaskTime
impl Unpin for PeriodicTaskTime
impl UnwindSafe for PeriodicTaskTime
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