#[repr(transparent)]pub struct JoiningType(pub u8);Expand description
Enumerated property Joining_Type. See Section 9.2, Arabic Cursive Joining in The Unicode Standard for the summary of each property value.
The numeric value is compatible with UJoiningType in ICU4C.
Tuple Fields§
§0: u8Implementations§
Source§impl JoiningType
impl JoiningType
pub const NonJoining: JoiningType
pub const JoinCausing: JoiningType
pub const DualJoining: JoiningType
pub const LeftJoining: JoiningType
pub const RightJoining: JoiningType
pub const Transparent: JoiningType
Source§impl JoiningType
impl JoiningType
Sourcepub const fn name_to_enum_mapper() -> PropertyValueNameToEnumMapperBorrowed<'static, JoiningType>
pub const fn name_to_enum_mapper() -> PropertyValueNameToEnumMapperBorrowed<'static, JoiningType>
Return a PropertyValueNameToEnumMapper, capable of looking up values
from strings for the Joining_Type enumerated property.
✨ Enabled with the compiled_data Cargo feature.
§Example
use icu::properties::JoiningType;
let lookup = JoiningType::name_to_enum_mapper();
// short name for value
assert_eq!(lookup.get_strict("T"), Some(JoiningType::Transparent));
assert_eq!(lookup.get_strict("D"), Some(JoiningType::DualJoining));
// long name for value
assert_eq!(lookup.get_strict("Join_Causing"), Some(JoiningType::JoinCausing));
assert_eq!(lookup.get_strict("Non_Joining"), Some(JoiningType::NonJoining));
// name has incorrect casing
assert_eq!(lookup.get_strict("LEFT_JOINING"), None);
// loose matching of name
assert_eq!(lookup.get_loose("LEFT_JOINING"), Some(JoiningType::LeftJoining));
// fake property
assert_eq!(lookup.get_strict("Inner_Joining"), None);Sourcepub fn get_name_to_enum_mapper(
provider: &(impl DataProvider<JoiningTypeNameToValueV1Marker> + ?Sized),
) -> Result<PropertyValueNameToEnumMapper<JoiningType>, PropertiesError>
pub fn get_name_to_enum_mapper( provider: &(impl DataProvider<JoiningTypeNameToValueV1Marker> + ?Sized), ) -> Result<PropertyValueNameToEnumMapper<JoiningType>, PropertiesError>
A version of JoiningType::name_to_enum_mapper() that uses custom data provided by a DataProvider.
Sourcepub const fn enum_to_short_name_mapper() -> PropertyEnumToValueNameLinearMapperBorrowed<'static, JoiningType>
pub const fn enum_to_short_name_mapper() -> PropertyEnumToValueNameLinearMapperBorrowed<'static, JoiningType>
Return a PropertyEnumToValueNameLinearMapper, capable of looking up short names
for values of the Joining_Type enumerated property.
✨ Enabled with the compiled_data Cargo feature.
§Example
use icu::properties::JoiningType;
let lookup = JoiningType::enum_to_short_name_mapper();
assert_eq!(lookup.get(JoiningType::JoinCausing), Some("C"));
assert_eq!(lookup.get(JoiningType::LeftJoining), Some("L"));Sourcepub fn get_enum_to_short_name_mapper(
provider: &(impl DataProvider<JoiningTypeValueToShortNameV1Marker> + ?Sized),
) -> Result<PropertyEnumToValueNameLinearMapper<JoiningType>, PropertiesError>
pub fn get_enum_to_short_name_mapper( provider: &(impl DataProvider<JoiningTypeValueToShortNameV1Marker> + ?Sized), ) -> Result<PropertyEnumToValueNameLinearMapper<JoiningType>, PropertiesError>
A version of JoiningType::enum_to_short_name_mapper() that uses custom data provided by a DataProvider.
Sourcepub const fn enum_to_long_name_mapper() -> PropertyEnumToValueNameLinearMapperBorrowed<'static, JoiningType>
pub const fn enum_to_long_name_mapper() -> PropertyEnumToValueNameLinearMapperBorrowed<'static, JoiningType>
Return a PropertyEnumToValueNameLinearMapper, capable of looking up long names
for values of the Joining_Type enumerated property.
✨ Enabled with the compiled_data Cargo feature.
§Example
use icu::properties::JoiningType;
let lookup = JoiningType::enum_to_long_name_mapper();
assert_eq!(lookup.get(JoiningType::Transparent), Some("Transparent"));
assert_eq!(lookup.get(JoiningType::NonJoining), Some("Non_Joining"));
assert_eq!(lookup.get(JoiningType::RightJoining), Some("Right_Joining"));Sourcepub fn get_enum_to_long_name_mapper(
provider: &(impl DataProvider<JoiningTypeValueToLongNameV1Marker> + ?Sized),
) -> Result<PropertyEnumToValueNameLinearMapper<JoiningType>, PropertiesError>
pub fn get_enum_to_long_name_mapper( provider: &(impl DataProvider<JoiningTypeValueToLongNameV1Marker> + ?Sized), ) -> Result<PropertyEnumToValueNameLinearMapper<JoiningType>, PropertiesError>
A version of JoiningType::enum_to_long_name_mapper() that uses custom data provided by a DataProvider.
Trait Implementations§
Source§impl AsULE for JoiningType
impl AsULE for JoiningType
Source§impl Clone for JoiningType
impl Clone for JoiningType
Source§fn clone(&self) -> JoiningType
fn clone(&self) -> JoiningType
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for JoiningType
impl Debug for JoiningType
Source§impl Hash for JoiningType
impl Hash for JoiningType
Source§impl Ord for JoiningType
impl Ord for JoiningType
Source§fn cmp(&self, other: &JoiningType) -> Ordering
fn cmp(&self, other: &JoiningType) -> Ordering
1.21.0 · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Source§impl PartialEq for JoiningType
impl PartialEq for JoiningType
Source§impl PartialOrd for JoiningType
impl PartialOrd for JoiningType
Source§impl TrieValue for JoiningType
impl TrieValue for JoiningType
Source§type TryFromU32Error = TryFromIntError
type TryFromU32Error = TryFromIntError
Source§fn try_from_u32(i: u32) -> Result<Self, Self::TryFromU32Error>
fn try_from_u32(i: u32) -> Result<Self, Self::TryFromU32Error>
u32 first.Source§impl<'a> ZeroMapKV<'a> for JoiningType
impl<'a> ZeroMapKV<'a> for JoiningType
Source§type Container = ZeroVec<'a, JoiningType>
type Container = ZeroVec<'a, JoiningType>
ZeroVec or VarZeroVec.type Slice = ZeroSlice<JoiningType>
Source§type OwnedType = JoiningType
type OwnedType = JoiningType
Container::replace() and Container::remove(),
also used during deserialization. If Self is human readable serialized,
deserializing to Self::OwnedType should produce the same value once
passed through Self::owned_as_self() Read moreimpl Copy for JoiningType
impl Eq for JoiningType
impl StructuralPartialEq for JoiningType
Auto Trait Implementations§
impl Freeze for JoiningType
impl RefUnwindSafe for JoiningType
impl Send for JoiningType
impl Sync for JoiningType
impl Unpin for JoiningType
impl UnwindSafe for JoiningType
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,
impl<T> ErasedDestructor for Twhere
T: 'static,
impl<T> MaybeSendSync for T
Layout§
Note: Most layout information is completely unstable and may even differ between compilations. The only exception is types with certain repr(...) attributes. Please see the Rust Reference's “Type Layout” chapter for details on type layout guarantees.
Size: 1 byte