pub struct MonthValue {
pub year: i32,
pub month: u8,
}Expand description
A year and month in the proleptic Gregorian calendar.
§Examples
use ailloli_ui_core::MonthValue;
assert_eq!(MonthValue::new(2026, 13).month, 12);Fields§
§year: i32Signed calendar year.
month: u8One-based month in 1..=12 for values created by MonthValue::new.
Implementations§
Trait Implementations§
Source§impl Clone for MonthValue
impl Clone for MonthValue
Source§fn clone(&self) -> MonthValue
fn clone(&self) -> MonthValue
Returns a copy 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 MonthValue
impl Debug for MonthValue
Source§impl Hash for MonthValue
impl Hash for MonthValue
Source§impl Ord for MonthValue
impl Ord for MonthValue
Source§fn cmp(&self, other: &MonthValue) -> Ordering
fn cmp(&self, other: &MonthValue) -> 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 MonthValue
impl PartialEq for MonthValue
Source§impl PartialOrd for MonthValue
impl PartialOrd for MonthValue
impl Copy for MonthValue
impl Eq for MonthValue
impl StructuralPartialEq for MonthValue
Auto Trait Implementations§
impl Freeze for MonthValue
impl RefUnwindSafe for MonthValue
impl Send for MonthValue
impl Sync for MonthValue
impl Unpin for MonthValue
impl UnwindSafe for MonthValue
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