#[non_exhaustive]pub struct Localizations(/* private fields */);Expand description
The localizations property: a map from LanguageTag to a
PatchObject that gives the localizable properties in that
language (draft-atwood-jmap-updates-00 §4.1).
Deserializing parses each key as a tag in canonical case and rejects
two keys that differ only in case. It does not check the patches;
check_localizations does that against the data type’s
LocalizableProperty list.
Implementations§
Source§impl Localizations
impl Localizations
Sourcepub fn get(&self, tag: &LanguageTag) -> Option<&PatchObject>
pub fn get(&self, tag: &LanguageTag) -> Option<&PatchObject>
The patch for tag, if any.
Sourcepub fn iter(&self) -> impl Iterator<Item = (&LanguageTag, &PatchObject)>
pub fn iter(&self) -> impl Iterator<Item = (&LanguageTag, &PatchObject)>
The localizations, in canonical tag order.
The language tags, in canonical order.
Trait Implementations§
Source§impl Clone for Localizations
impl Clone for Localizations
Source§impl Debug for Localizations
impl Debug for Localizations
Source§impl Default for Localizations
impl Default for Localizations
Source§impl<'de> Deserialize<'de> for Localizations
impl<'de> Deserialize<'de> for Localizations
Source§fn deserialize<D: Deserializer<'de>>(d: D) -> Result<Self, D::Error>
fn deserialize<D: Deserializer<'de>>(d: D) -> Result<Self, D::Error>
Deserialize this value from the given Serde deserializer. Read more
impl Eq for Localizations
Source§impl PartialEq for Localizations
impl PartialEq for Localizations
Source§impl Serialize for Localizations
impl Serialize for Localizations
impl StructuralPartialEq for Localizations
Auto Trait Implementations§
impl Forget for Localizations
impl Freeze for Localizations
impl Move for Localizations
impl RefUnwindSafe for Localizations
impl Send for Localizations
impl Sync for Localizations
impl Unpin for Localizations
impl UnsafeUnpin for Localizations
impl UnwindSafe for Localizations
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