pub struct CalendarDate { /* private fields */ }Implementations§
Source§impl CalendarDate
impl CalendarDate
Sourcepub fn new(year_month: CalendarYearMonth, day: DayOfMonth) -> Self
pub fn new(year_month: CalendarYearMonth, day: DayOfMonth) -> Self
コンストラクタ
pub fn as_year_month(&self) -> &CalendarYearMonth
pub fn to_year_month(&self) -> CalendarYearMonth
pub fn as_day(&self) -> &DayOfMonth
pub fn to_day(&self) -> DayOfMonth
pub fn to_date_time_on_midnight_at_utc(&self) -> DateTime<Utc>
pub fn to_date_time_on_midnight<T: TimeZone>(&self, time_zone: T) -> DateTime<T>
pub fn day_of_week_at_utc(&self) -> DayOfWeek
pub fn day_of_week<T: TimeZone>(&self, time_zone: T) -> DayOfWeek
pub fn add_days<T>(&self, days: i64, time_zone: T) -> Selfwhere
T: TimeZone,
pub fn subtract_days<T>(&self, days: i64, time_zone: T) -> Selfwhere
T: TimeZone,
pub fn subtract_months<T>(&self, months: i64, time_zone: T) -> Selfwhere
T: TimeZone,
pub fn add_months<T>(&self, months: i64, time_zone: T) -> Selfwhere
T: TimeZone,
pub fn is_after(&self, other: &Self) -> bool
pub fn is_before(&self, other: &Self) -> bool
Trait Implementations§
Source§impl Clone for CalendarDate
impl Clone for CalendarDate
Source§fn clone(&self) -> CalendarDate
fn clone(&self) -> CalendarDate
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 CalendarDate
impl Debug for CalendarDate
Source§impl From<(CalendarYearMonth, DayOfMonth)> for CalendarDate
impl From<(CalendarYearMonth, DayOfMonth)> for CalendarDate
Source§fn from((year_month, day): (CalendarYearMonth, DayOfMonth)) -> Self
fn from((year_month, day): (CalendarYearMonth, DayOfMonth)) -> Self
Converts to this type from the input type.
Source§impl From<TimePoint> for CalendarDate
impl From<TimePoint> for CalendarDate
Source§impl Hash for CalendarDate
impl Hash for CalendarDate
Source§impl PartialEq for CalendarDate
impl PartialEq for CalendarDate
Source§impl PartialOrd for CalendarDate
impl PartialOrd for CalendarDate
Source§impl ToString for CalendarDate
impl ToString for CalendarDate
impl Eq for CalendarDate
impl StructuralPartialEq for CalendarDate
Auto Trait Implementations§
impl Freeze for CalendarDate
impl RefUnwindSafe for CalendarDate
impl Send for CalendarDate
impl Sync for CalendarDate
impl Unpin for CalendarDate
impl UnwindSafe for CalendarDate
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