Struct ucd_parse::UnicodeData
source · pub struct UnicodeData {Show 15 fields
pub codepoint: Codepoint,
pub name: String,
pub general_category: String,
pub canonical_combining_class: u8,
pub bidi_class: String,
pub decomposition: UnicodeDataDecomposition,
pub numeric_type_decimal: Option<u8>,
pub numeric_type_digit: Option<u8>,
pub numeric_type_numeric: Option<UnicodeDataNumeric>,
pub bidi_mirrored: bool,
pub unicode1_name: String,
pub iso_comment: String,
pub simple_uppercase_mapping: Option<Codepoint>,
pub simple_lowercase_mapping: Option<Codepoint>,
pub simple_titlecase_mapping: Option<Codepoint>,
}
Expand description
Represents a single row in the UnicodeData.txt
file.
These fields were taken from UAX44, Table 9, as part of the documentation
for the
UnicodeData.txt
file.
Fields§
§codepoint: Codepoint
The codepoint corresponding to this row.
name: String
The name of this codepoint.
general_category: String
The “general category” of this codepoint.
canonical_combining_class: u8
The class of this codepoint used in the Canonical Ordering Algorithm.
Note that some classes map to a particular symbol. See UAX44, Table 15.
bidi_class: String
The bidirectional class of this codepoint.
Possible values are listed in UAX44, Table 13.
decomposition: UnicodeDataDecomposition
The decomposition mapping for this codepoint. This includes its formatting tag (if present).
numeric_type_decimal: Option<u8>
A decimal numeric representation of this codepoint, if it has the
property Numeric_Type=Decimal
.
numeric_type_digit: Option<u8>
A decimal numeric representation of this codepoint, if it has the
property Numeric_Type=Digit
. Note that while this field is still
populated for existing codepoints, no new codepoints will have this
field populated.
numeric_type_numeric: Option<UnicodeDataNumeric>
A decimal or rational numeric representation of this codepoint, if it
has the property Numeric_Type=Numeric
.
bidi_mirrored: bool
A boolean indicating whether this codepoint is “mirrored” in bidirectional text.
unicode1_name: String
The “old” Unicode 1.0 or ISO 6429 name of this codepoint. Note that
this field is empty unless it is significantly different from
the name
field.
iso_comment: String
The ISO 10464 comment field. This no longer contains any non-NULL values.
simple_uppercase_mapping: Option<Codepoint>
This codepoint’s simple uppercase mapping, if it exists.
simple_lowercase_mapping: Option<Codepoint>
This codepoint’s simple lowercase mapping, if it exists.
simple_titlecase_mapping: Option<Codepoint>
This codepoint’s simple titlecase mapping, if it exists.
Implementations§
source§impl UnicodeData
impl UnicodeData
sourcepub fn is_range_start(&self) -> bool
pub fn is_range_start(&self) -> bool
Returns true if and only if this record corresponds to the start of a range.
sourcepub fn is_range_end(&self) -> bool
pub fn is_range_end(&self) -> bool
Returns true if and only if this record corresponds to the end of a range.
Trait Implementations§
source§impl Clone for UnicodeData
impl Clone for UnicodeData
source§fn clone(&self) -> UnicodeData
fn clone(&self) -> UnicodeData
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moresource§impl Debug for UnicodeData
impl Debug for UnicodeData
source§impl Default for UnicodeData
impl Default for UnicodeData
source§fn default() -> UnicodeData
fn default() -> UnicodeData
source§impl Display for UnicodeData
impl Display for UnicodeData
source§impl FromStr for UnicodeData
impl FromStr for UnicodeData
source§impl PartialEq for UnicodeData
impl PartialEq for UnicodeData
source§fn eq(&self, other: &UnicodeData) -> bool
fn eq(&self, other: &UnicodeData) -> bool
self
and other
values to be equal, and is used
by ==
.source§impl UcdFile for UnicodeData
impl UcdFile for UnicodeData
source§impl UcdFileByCodepoint for UnicodeData
impl UcdFileByCodepoint for UnicodeData
source§fn codepoints(&self) -> CodepointIter ⓘ
fn codepoints(&self) -> CodepointIter ⓘ
impl Eq for UnicodeData
impl StructuralPartialEq for UnicodeData
Auto Trait Implementations§
impl Freeze for UnicodeData
impl RefUnwindSafe for UnicodeData
impl Send for UnicodeData
impl Sync for UnicodeData
impl Unpin for UnicodeData
impl UnwindSafe for UnicodeData
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,
source§default unsafe fn clone_to_uninit(&self, dst: *mut T)
default unsafe fn clone_to_uninit(&self, dst: *mut T)
clone_to_uninit
)