pub struct CalendarYearMonth { /* private fields */ }Implementations§
Source§impl CalendarYearMonth
impl CalendarYearMonth
pub fn new(year: i32, month: MonthOfYear) -> Self
pub fn to_year(&self) -> i32
pub fn as_month_of_year(&self) -> &MonthOfYear
pub fn as_month(&self) -> &Month
pub fn to_month_u32(&self) -> u32
pub fn as_last_day_of_month(&self) -> &DayOfMonth
pub fn add_month(&mut self) -> &Self
pub fn parse_tz<T>(
date_str: &str,
pattern: &str,
time_zone: T,
) -> Result<Self, ParseError>where
T: TimeZone,
pub fn is_after(&self, other: &Self) -> bool
pub fn is_before(&self, other: &Self) -> bool
Trait Implementations§
Source§impl Clone for CalendarYearMonth
impl Clone for CalendarYearMonth
Source§fn clone(&self) -> CalendarYearMonth
fn clone(&self) -> CalendarYearMonth
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 CalendarYearMonth
impl Debug for CalendarYearMonth
Source§impl From<(i32, MonthOfYear)> for CalendarYearMonth
impl From<(i32, MonthOfYear)> for CalendarYearMonth
Source§fn from((year, month): (i32, MonthOfYear)) -> Self
fn from((year, month): (i32, MonthOfYear)) -> Self
Converts to this type from the input type.
Source§impl From<TimePoint> for CalendarYearMonth
impl From<TimePoint> for CalendarYearMonth
Source§impl Hash for CalendarYearMonth
impl Hash for CalendarYearMonth
Source§impl PartialEq for CalendarYearMonth
impl PartialEq for CalendarYearMonth
Source§impl PartialOrd for CalendarYearMonth
impl PartialOrd for CalendarYearMonth
impl Eq for CalendarYearMonth
impl StructuralPartialEq for CalendarYearMonth
Auto Trait Implementations§
impl Freeze for CalendarYearMonth
impl RefUnwindSafe for CalendarYearMonth
impl Send for CalendarYearMonth
impl Sync for CalendarYearMonth
impl Unpin for CalendarYearMonth
impl UnwindSafe for CalendarYearMonth
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