pub struct IsoTime { /* private fields */ }
Expand description
An ISO-8601 time, with an optional timezone specifier.
Implementations§
source§impl IsoTime
impl IsoTime
sourcepub fn new(hour: u8, minute: u8, second: u8) -> Self
pub fn new(hour: u8, minute: u8, second: u8) -> Self
Create a new IsoDate
with the given day, month and year.
sourcepub fn with_fraction<F>(self, fraction: F) -> Selfwhere
F: Into<Option<f32>>,
pub fn with_fraction<F>(self, fraction: F) -> Selfwhere F: Into<Option<f32>>,
Change the fraction component of the IsoTime
.
sourcepub fn with_timezone<TZ>(self, timezone: TZ) -> Selfwhere
TZ: Into<Option<IsoTimezone>>,
pub fn with_timezone<TZ>(self, timezone: TZ) -> Selfwhere TZ: Into<Option<IsoTimezone>>,
Change the timezone component of the IsoTime
.
sourcepub fn timezone(&self) -> Option<&IsoTimezone>
pub fn timezone(&self) -> Option<&IsoTimezone>
Get the timezone of the IsoTime
, if any.
Trait Implementations§
source§impl AsMut<IsoTime> for IsoDateTime
impl AsMut<IsoTime> for IsoDateTime
source§impl AsRef<IsoTime> for IsoDateTime
impl AsRef<IsoTime> for IsoDateTime
source§impl<'i> FromPair<'i> for IsoTime
impl<'i> FromPair<'i> for IsoTime
source§impl Ord for IsoTime
impl Ord for IsoTime
source§impl PartialEq<IsoTime> for IsoTime
impl PartialEq<IsoTime> for IsoTime
source§impl PartialOrd<IsoTime> for IsoTime
impl PartialOrd<IsoTime> for IsoTime
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self
and other
) and is used by the <=
operator. Read moreimpl Eq for IsoTime
impl StructuralEq for IsoTime
impl StructuralPartialEq for IsoTime
Auto Trait Implementations§
impl RefUnwindSafe for IsoTime
impl Send for IsoTime
impl Sync for IsoTime
impl Unpin for IsoTime
impl UnwindSafe for IsoTime
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