Struct icu::locid_transform::provider::StrStrPair
source · pub struct StrStrPair<'a>(pub Cow<'a, str>, pub Cow<'a, str>);
Expand description
A pair of strings with a EncodeAsVarULE implementation.
🚧 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.
Tuple Fields§
§0: Cow<'a, str>
§1: Cow<'a, str>
Trait Implementations§
source§impl<'a> Clone for StrStrPair<'a>
impl<'a> Clone for StrStrPair<'a>
source§fn clone(&self) -> StrStrPair<'a>
fn clone(&self) -> StrStrPair<'a>
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<'a> Debug for StrStrPair<'a>
impl<'a> Debug for StrStrPair<'a>
source§impl<'de, 'a> Deserialize<'de> for StrStrPair<'a>where
'de: 'a,
impl<'de, 'a> Deserialize<'de> for StrStrPair<'a>where 'de: 'a,
source§fn deserialize<__D>(
__deserializer: __D
) -> Result<StrStrPair<'a>, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>( __deserializer: __D ) -> Result<StrStrPair<'a>, <__D as Deserializer<'de>>::Error>where __D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl<'a> EncodeAsVarULE<StrStrPairVarULE> for &StrStrPair<'a>
impl<'a> EncodeAsVarULE<StrStrPairVarULE> for &StrStrPair<'a>
source§fn encode_var_ule_as_slices<R>(&self, cb: impl FnOnce(&[&[u8]]) -> R) -> R
fn encode_var_ule_as_slices<R>(&self, cb: impl FnOnce(&[&[u8]]) -> R) -> R
Calls
cb
with a piecewise list of byte slices that when concatenated
produce the memory pattern of the corresponding instance of T
. Read moresource§fn encode_var_ule_len(&self) -> usize
fn encode_var_ule_len(&self) -> usize
Return the length, in bytes, of the corresponding [
VarULE
] typesource§fn encode_var_ule_write(&self, dst: &mut [u8])
fn encode_var_ule_write(&self, dst: &mut [u8])
Write the corresponding [
VarULE
] type to the dst
buffer. dst
should
be the size of [Self::encode_var_ule_len()
]source§impl<'a> EncodeAsVarULE<StrStrPairVarULE> for StrStrPair<'a>
impl<'a> EncodeAsVarULE<StrStrPairVarULE> for StrStrPair<'a>
source§fn encode_var_ule_as_slices<R>(&self, cb: impl FnOnce(&[&[u8]]) -> R) -> R
fn encode_var_ule_as_slices<R>(&self, cb: impl FnOnce(&[&[u8]]) -> R) -> R
Calls
cb
with a piecewise list of byte slices that when concatenated
produce the memory pattern of the corresponding instance of T
. Read moresource§fn encode_var_ule_len(&self) -> usize
fn encode_var_ule_len(&self) -> usize
Return the length, in bytes, of the corresponding [
VarULE
] typesource§fn encode_var_ule_write(&self, dst: &mut [u8])
fn encode_var_ule_write(&self, dst: &mut [u8])
Write the corresponding [
VarULE
] type to the dst
buffer. dst
should
be the size of [Self::encode_var_ule_len()
]source§impl<'a> Ord for StrStrPair<'a>
impl<'a> Ord for StrStrPair<'a>
source§fn cmp(&self, other: &StrStrPair<'a>) -> Ordering
fn cmp(&self, other: &StrStrPair<'a>) -> 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<'a> PartialEq<StrStrPair<'a>> for StrStrPair<'a>
impl<'a> PartialEq<StrStrPair<'a>> for StrStrPair<'a>
source§fn eq(&self, other: &StrStrPair<'a>) -> bool
fn eq(&self, other: &StrStrPair<'a>) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl<'a> PartialOrd<StrStrPair<'a>> for StrStrPair<'a>
impl<'a> PartialOrd<StrStrPair<'a>> for StrStrPair<'a>
source§fn partial_cmp(&self, other: &StrStrPair<'a>) -> Option<Ordering>
fn partial_cmp(&self, other: &StrStrPair<'a>) -> Option<Ordering>
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self
and other
) and is used by the <=
operator. Read moresource§impl<'a> ZeroFrom<'a, StrStrPairVarULE> for StrStrPair<'a>
impl<'a> ZeroFrom<'a, StrStrPairVarULE> for StrStrPair<'a>
source§fn zero_from(other: &'a StrStrPairVarULE) -> StrStrPair<'a>
fn zero_from(other: &'a StrStrPairVarULE) -> StrStrPair<'a>
Clone the other
C
into a struct that may retain references into C
.