#[non_exhaustive]pub enum CalendarAlgorithm {
Show 14 variants
    Buddhist,
    Chinese,
    Coptic,
    Dangi,
    Ethioaa,
    Ethiopic,
    Gregory,
    Hebrew,
    Indian,
    Hijri(Option<HijriCalendarAlgorithm>),
    Iso8601,
    Japanese,
    Persian,
    Roc,
}Expand description
A Unicode Calendar Identifier defines a type of calendar.
This selects calendar-specific data within a locale used for formatting and parsing, such as date/time symbols and patterns; it also selects supplemental calendarData used for calendrical calculations. The value can affect the computation of the first day of the week.
The valid values are listed in LDML.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Buddhist
Thai Buddhist calendar (same as Gregorian except for the year)
Chinese
Traditional Chinese calendar
Coptic
Coptic calendar
Dangi
Traditional Korean calendar
Ethioaa
Ethiopic calendar, Amete Alem (epoch approx. 5493 B.C.E)
Ethiopic
Ethiopic calendar, Amete Mihret (epoch approx, 8 C.E.)
Gregory
Gregorian calendar
Hebrew
Traditional Hebrew calendar
Indian
Indian calendar
Hijri(Option<HijriCalendarAlgorithm>)
Hijri calendar
Iso8601
ISO calendar (Gregorian calendar using the ISO 8601 calendar week rules)
Japanese
Japanese Imperial calendar
Persian
Persian calendar
Roc
Republic of China calendar
Implementations§
Trait Implementations§
Source§impl Clone for CalendarAlgorithm
 
impl Clone for CalendarAlgorithm
Source§fn clone(&self) -> CalendarAlgorithm
 
fn clone(&self) -> CalendarAlgorithm
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
 
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for CalendarAlgorithm
 
impl Debug for CalendarAlgorithm
Source§impl From<CalendarAlgorithm> for Value
 
impl From<CalendarAlgorithm> for Value
Source§fn from(input: CalendarAlgorithm) -> Value
 
fn from(input: CalendarAlgorithm) -> Value
Source§impl Hash for CalendarAlgorithm
 
impl Hash for CalendarAlgorithm
Source§impl PartialEq for CalendarAlgorithm
 
impl PartialEq for CalendarAlgorithm
Source§impl PreferenceKey for CalendarAlgorithm
 
impl PreferenceKey for CalendarAlgorithm
Source§fn unicode_extension_key() -> Option<Key>
 
fn unicode_extension_key() -> Option<Key>
Source§fn try_from_key_value(
    key: &Key,
    value: &Value,
) -> Result<Option<CalendarAlgorithm>, PreferencesParseError>
 
fn try_from_key_value( key: &Key, value: &Value, ) -> Result<Option<CalendarAlgorithm>, PreferencesParseError>
Source§fn unicode_extension_value(&self) -> Option<Value>
 
fn unicode_extension_value(&self) -> Option<Value>
Source§impl TryFrom<&Value> for CalendarAlgorithm
 
impl TryFrom<&Value> for CalendarAlgorithm
Source§type Error = PreferencesParseError
 
type Error = PreferencesParseError
Source§fn try_from(
    s: &Value,
) -> Result<CalendarAlgorithm, <CalendarAlgorithm as TryFrom<&Value>>::Error>
 
fn try_from( s: &Value, ) -> Result<CalendarAlgorithm, <CalendarAlgorithm as TryFrom<&Value>>::Error>
Source§impl TryFrom<CalendarAlgorithm> for AnyCalendarKind
 
impl TryFrom<CalendarAlgorithm> for AnyCalendarKind
Source§fn try_from(
    v: CalendarAlgorithm,
) -> Result<AnyCalendarKind, <AnyCalendarKind as TryFrom<CalendarAlgorithm>>::Error>
 
fn try_from( v: CalendarAlgorithm, ) -> Result<AnyCalendarKind, <AnyCalendarKind as TryFrom<CalendarAlgorithm>>::Error>
impl Copy for CalendarAlgorithm
impl Eq for CalendarAlgorithm
impl StructuralPartialEq for CalendarAlgorithm
Auto Trait Implementations§
impl Freeze for CalendarAlgorithm
impl RefUnwindSafe for CalendarAlgorithm
impl Send for CalendarAlgorithm
impl Sync for CalendarAlgorithm
impl Unpin for CalendarAlgorithm
impl UnwindSafe for CalendarAlgorithm
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
Source§impl<T> CloneToUninit for Twhere
    T: Clone,
 
impl<T> CloneToUninit for Twhere
    T: Clone,
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>
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>
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