pub struct PartialDateTime {
pub year: Option<u16>,
pub month: Option<u8>,
pub day: Option<u8>,
pub hour: Option<u8>,
pub minute: Option<u8>,
pub second: Option<u8>,
pub tz_hour: Option<u8>,
pub tz_minute: Option<u8>,
pub tz_minus: bool,
}
Fields§
§year: Option<u16>
§month: Option<u8>
§day: Option<u8>
§hour: Option<u8>
§minute: Option<u8>
§second: Option<u8>
§tz_hour: Option<u8>
§tz_minute: Option<u8>
§tz_minus: bool
Implementations§
Source§impl PartialDateTime
impl PartialDateTime
pub fn parse_timestamp( &mut self, iter: &mut Peekable<Iter<'_, u8>>, require_time: bool, ) -> bool
pub fn is_null(&self) -> bool
pub fn has_date(&self) -> bool
pub fn has_time(&self) -> bool
pub fn has_zone(&self) -> bool
pub fn has_date_and_time(&self) -> bool
pub fn to_rfc3339(&self) -> Option<String>
pub fn to_timestamp(&self) -> Option<i64>
Source§impl PartialDateTime
impl PartialDateTime
pub fn now() -> Self
pub fn from_utc_timestamp(value: i64) -> Self
pub fn from_naive_timestamp(value: i64) -> Self
pub fn to_date_time(&self) -> Option<DateTimeResult>
Source§impl PartialDateTime
impl PartialDateTime
pub fn format_as_ical( &self, out: &mut impl Write, fmt: &ICalendarValueType, ) -> Result
Source§impl PartialDateTime
impl PartialDateTime
pub fn parse_vcard_date_legacy( &mut self, iter: &mut Peekable<Iter<'_, u8>>, ) -> bool
pub fn parse_vcard_zone_legacy( &mut self, iter: &mut Peekable<Iter<'_, u8>>, ) -> bool
pub fn parse_vcard_date_time(&mut self, iter: &mut Peekable<Iter<'_, u8>>)
pub fn parse_vcard_date_and_or_time( &mut self, iter: &mut Peekable<Iter<'_, u8>>, )
pub fn parse_vcard_date(&mut self, iter: &mut Peekable<Iter<'_, u8>>)
pub fn parse_vcard_date_noreduc(&mut self, iter: &mut Peekable<Iter<'_, u8>>)
pub fn parse_vcard_time( &mut self, iter: &mut Peekable<Iter<'_, u8>>, notrunc: bool, )
Source§impl PartialDateTime
impl PartialDateTime
pub fn format_as_vcard( &self, out: &mut impl Write, fmt: &VCardValueType, ) -> Result
pub fn format_as_legacy_vcard( &self, out: &mut impl Write, fmt: &VCardValueType, ) -> Result
Trait Implementations§
Source§impl Clone for PartialDateTime
impl Clone for PartialDateTime
Source§fn clone(&self) -> PartialDateTime
fn clone(&self) -> PartialDateTime
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 PartialDateTime
impl Debug for PartialDateTime
Source§impl Default for PartialDateTime
impl Default for PartialDateTime
Source§fn default() -> PartialDateTime
fn default() -> PartialDateTime
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for PartialDateTime
impl<'de> Deserialize<'de> for PartialDateTime
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl From<JSCalendarDateTime> for PartialDateTime
impl From<JSCalendarDateTime> for PartialDateTime
Source§fn from(dt: JSCalendarDateTime) -> Self
fn from(dt: JSCalendarDateTime) -> Self
Converts to this type from the input type.
Source§impl From<PartialDateTime> for ICalendarValue
impl From<PartialDateTime> for ICalendarValue
Source§fn from(value: PartialDateTime) -> Self
fn from(value: PartialDateTime) -> Self
Converts to this type from the input type.
Source§impl Hash for PartialDateTime
impl Hash for PartialDateTime
Source§impl Ord for PartialDateTime
impl Ord for PartialDateTime
Source§fn cmp(&self, other: &PartialDateTime) -> Ordering
fn cmp(&self, other: &PartialDateTime) -> Ordering
1.21.0 · 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 PartialDateTime
impl PartialEq for PartialDateTime
Source§impl PartialOrd for PartialDateTime
impl PartialOrd for PartialDateTime
Source§impl Serialize for PartialDateTime
impl Serialize for PartialDateTime
impl Eq for PartialDateTime
impl StructuralPartialEq for PartialDateTime
Auto Trait Implementations§
impl Freeze for PartialDateTime
impl RefUnwindSafe for PartialDateTime
impl Send for PartialDateTime
impl Sync for PartialDateTime
impl Unpin for PartialDateTime
impl UnwindSafe for PartialDateTime
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