pub struct Eras<'data> {
pub names: ZeroMap<'data, str, str>,
pub abbr: ZeroMap<'data, str, str>,
pub narrow: ZeroMap<'data, str, str>,
}
Expand description
String data for the name, abbreviation, and narrow form of a date’s era.
Keys of the map represent era codes, and the values are the display names.
Era codes are derived from CLDR data, and are calendar specific.
Some examples include: "be"
, "0"
/ "1"
, "bce"
/ "ce"
,
"heisei"
/ "meiji"
/ "reiwa"
/ … Not all era codes are inherited as-is,
such as for the extended Japanese calendar.
For more information on date time symbols, see FieldSymbol
.
🚧 This code is considered unstable; it may change at any time, in breaking or non-breaking ways,
including in SemVer minor releases. While the serde representation of data structs is guaranteed
to be stable, their Rust representation might not be. Use with caution.
Fields§
§names: ZeroMap<'data, str, str>
Symbol data for era names.
Keys are era codes, and values are display names. See Eras
.
abbr: ZeroMap<'data, str, str>
Symbol data for era abbreviations.
Keys are era codes, and values are display names. See Eras
.
narrow: ZeroMap<'data, str, str>
Symbol data for era narrow forms.
Keys are era codes, and values are display names. See Eras
.
Trait Implementations§
source§impl<'de, 'data> Deserialize<'de> for Eras<'data>where
'de: 'data,
impl<'de, 'data> Deserialize<'de> for Eras<'data>where 'de: 'data,
source§fn deserialize<__D>(
__deserializer: __D
) -> Result<Eras<'data>, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>( __deserializer: __D ) -> Result<Eras<'data>, <__D as Deserializer<'de>>::Error>where __D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more