Struct rp2040_hal::rtc::DateTimeFilter
source · pub struct DateTimeFilter {
pub year: Option<u16>,
pub month: Option<u8>,
pub day: Option<u8>,
pub day_of_week: Option<DayOfWeek>,
pub hour: Option<u8>,
pub minute: Option<u8>,
pub second: Option<u8>,
}
Expand description
A filter used for RealTimeClock::schedule_alarm
.
Fields§
§year: Option<u16>
The year that this alarm should trigger on, None
if the RTC alarm should not trigger on a year value.
month: Option<u8>
The month that this alarm should trigger on, None
if the RTC alarm should not trigger on a month value.
day: Option<u8>
The day that this alarm should trigger on, None
if the RTC alarm should not trigger on a day value.
day_of_week: Option<DayOfWeek>
The day of week that this alarm should trigger on, None
if the RTC alarm should not trigger on a day of week value.
hour: Option<u8>
The hour that this alarm should trigger on, None
if the RTC alarm should not trigger on a hour value.
minute: Option<u8>
The minute that this alarm should trigger on, None
if the RTC alarm should not trigger on a minute value.
second: Option<u8>
The second that this alarm should trigger on, None
if the RTC alarm should not trigger on a second value.
Implementations§
source§impl DateTimeFilter
impl DateTimeFilter
sourcepub fn day_of_week(self, day_of_week: DayOfWeek) -> Self
pub fn day_of_week(self, day_of_week: DayOfWeek) -> Self
Set a filter on the given day of the week
Trait Implementations§
source§impl Default for DateTimeFilter
impl Default for DateTimeFilter
source§fn default() -> DateTimeFilter
fn default() -> DateTimeFilter
Auto Trait Implementations§
impl Freeze for DateTimeFilter
impl RefUnwindSafe for DateTimeFilter
impl Send for DateTimeFilter
impl Sync for DateTimeFilter
impl Unpin for DateTimeFilter
impl UnwindSafe for DateTimeFilter
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
source§impl<Choices> CoproductSubsetter<CNil, HNil> for Choices
impl<Choices> CoproductSubsetter<CNil, HNil> for Choices
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