pub struct LanguageMap { /* private fields */ }Expand description
Multiple language-tagged values.
Implementations§
Source§impl LanguageMap
impl LanguageMap
Sourcepub fn new() -> Self
pub fn new() -> Self
Creates a new LanguageMap.
Sourcepub fn map_mut(&mut self) -> &mut BTreeMap<LanguageTag, String>
pub fn map_mut(&mut self) -> &mut BTreeMap<LanguageTag, String>
Gets a mutable reference to the map.
Source§impl LanguageMap
impl LanguageMap
Sourcepub fn map(&self) -> &BTreeMap<LanguageTag, String>
pub fn map(&self) -> &BTreeMap<LanguageTag, String>
Gets the LanguageMap map.
Inner mapping of LanguageTag to content string in that language.
Sourcepub fn set_map<I: Into<BTreeMap<LanguageTag, String>>>(&mut self, val: I)
pub fn set_map<I: Into<BTreeMap<LanguageTag, String>>>(&mut self, val: I)
Sets the LanguageMap map.
Inner mapping of LanguageTag to content string in that language.
Sourcepub fn with_map<I: Into<BTreeMap<LanguageTag, String>>>(self, val: I) -> Self
pub fn with_map<I: Into<BTreeMap<LanguageTag, String>>>(self, val: I) -> Self
Builder function that sets the LanguageMap map.
Inner mapping of LanguageTag to content string in that language.
Trait Implementations§
Source§impl Clone for LanguageMap
impl Clone for LanguageMap
Source§fn clone(&self) -> LanguageMap
fn clone(&self) -> LanguageMap
Returns a duplicate 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 LanguageMap
impl Debug for LanguageMap
Source§impl Default for LanguageMap
impl Default for LanguageMap
Source§impl<'de> Deserialize<'de> for LanguageMap
impl<'de> Deserialize<'de> for LanguageMap
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Display for LanguageMap
impl Display for LanguageMap
Source§impl Ord for LanguageMap
impl Ord for LanguageMap
Source§fn cmp(&self, other: &LanguageMap) -> Ordering
fn cmp(&self, other: &LanguageMap) -> 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 LanguageMap
impl PartialEq for LanguageMap
Source§impl PartialOrd for LanguageMap
impl PartialOrd for LanguageMap
Source§impl Serialize for LanguageMap
impl Serialize for LanguageMap
impl Eq for LanguageMap
impl StructuralPartialEq for LanguageMap
Auto Trait Implementations§
impl Freeze for LanguageMap
impl RefUnwindSafe for LanguageMap
impl Send for LanguageMap
impl Sync for LanguageMap
impl Unpin for LanguageMap
impl UnsafeUnpin for LanguageMap
impl UnwindSafe for LanguageMap
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§impl<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.