pub struct LocalParts {
pub date: LocalDate,
pub time: LocalTime,
pub iso_weekday: u8,
}Expand description
A wall-clock reading: the date, the time of day, and the day of the week.
What an OCPI restriction is written against. start_time, end_time and day_of_week are all
“in local time, the time zone is defined in the time_zone field of the Location”, so a
consumer needs the instant converted, not the instant.
Produced by TimeZone::to_local. The fields are this
crate’s own types, so no date-time library appears in the API and the backend stays
replaceable.
Fields§
§date: LocalDateThe local calendar date.
time: LocalTimeThe local time of day, to the minute.
iso_weekday: u8The ISO-8601 day of the week: Monday is 1, Sunday is 7.
Trait Implementations§
Source§impl Clone for LocalParts
impl Clone for LocalParts
Source§fn clone(&self) -> LocalParts
fn clone(&self) -> LocalParts
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 LocalParts
Source§impl Debug for LocalParts
impl Debug for LocalParts
impl Eq for LocalParts
Source§impl PartialEq for LocalParts
impl PartialEq for LocalParts
impl StructuralPartialEq for LocalParts
Auto Trait Implementations§
impl Freeze for LocalParts
impl RefUnwindSafe for LocalParts
impl Send for LocalParts
impl Sync for LocalParts
impl Unpin for LocalParts
impl UnsafeUnpin for LocalParts
impl UnwindSafe for LocalParts
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.