Struct icu_datetime::input::FormattableMonth
source · pub(crate) struct FormattableMonth {
pub ordinal: u32,
pub code: MonthCode,
}
Expand description
Representation of a formattable month.
Fields§
§ordinal: u32
The month number in this given year. For calendars with leap months, all months after the leap month will end up with an incremented number.
In general, prefer using the month code in generic code.
code: MonthCode
The month code, used to distinguish months during leap years.
This may not necessarily be the canonical month code for a month in cases where a month has different formatting in a leap year, for example Adar/Adar II in the Hebrew calendar in a leap year has the code M06, but for formatting specifically the Hebrew calendar will return M06L since it is formatted differently.
Trait Implementations§
source§impl Clone for FormattableMonth
impl Clone for FormattableMonth
source§fn clone(&self) -> FormattableMonth
fn clone(&self) -> FormattableMonth
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 FormattableMonth
impl Debug for FormattableMonth
source§impl PartialEq for FormattableMonth
impl PartialEq for FormattableMonth
impl Copy for FormattableMonth
impl StructuralPartialEq for FormattableMonth
Auto Trait Implementations§
impl Freeze for FormattableMonth
impl RefUnwindSafe for FormattableMonth
impl Send for FormattableMonth
impl Sync for FormattableMonth
impl Unpin for FormattableMonth
impl UnwindSafe for FormattableMonth
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
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)source§impl<T> IntoEither for T
impl<T> IntoEither for T
source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moresource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more