Struct idna_adapter::Adapter
source · pub struct Adapter {
pub(crate) mapper: Uts46Mapper,
pub(crate) canonical_combining_class: CanonicalCombiningClassMap,
pub(crate) general_category: CodePointMapDataBorrowed<'static, GeneralCategory>,
pub(crate) bidi_class: CodePointMapDataBorrowed<'static, BidiClass>,
pub(crate) joining_type: CodePointMapDataBorrowed<'static, JoiningType>,
}
Expand description
An adapter between a Unicode back end an the idna
crate.
Fields§
§mapper: Uts46Mapper
§canonical_combining_class: CanonicalCombiningClassMap
§general_category: CodePointMapDataBorrowed<'static, GeneralCategory>
§bidi_class: CodePointMapDataBorrowed<'static, BidiClass>
§joining_type: CodePointMapDataBorrowed<'static, JoiningType>
Implementations§
source§impl Adapter
impl Adapter
sourcepub fn is_virama(&self, c: char) -> bool
pub fn is_virama(&self, c: char) -> bool
true
iff the Canonical_Combining_Class of c
is Virama.
sourcepub fn is_mark(&self, c: char) -> bool
pub fn is_mark(&self, c: char) -> bool
true
iff the General_Category of c
is Mark, i.e. any of Nonspacing_Mark,
Spacing_Mark, or Enclosing_Mark.
sourcepub fn bidi_class(&self, c: char) -> BidiClass
pub fn bidi_class(&self, c: char) -> BidiClass
Returns the Bidi_Class of c
.
sourcepub fn joining_type(&self, c: char) -> JoiningType
pub fn joining_type(&self, c: char) -> JoiningType
Returns the Joining_Type of c
.
sourcepub fn map_normalize<'delegate, I: Iterator<Item = char> + 'delegate>(
&'delegate self,
iter: I,
) -> impl Iterator<Item = char> + 'delegate
pub fn map_normalize<'delegate, I: Iterator<Item = char> + 'delegate>( &'delegate self, iter: I, ) -> impl Iterator<Item = char> + 'delegate
See the method of the same name in icu_normalizer
for the
exact semantics.
sourcepub fn normalize_validate<'delegate, I: Iterator<Item = char> + 'delegate>(
&'delegate self,
iter: I,
) -> impl Iterator<Item = char> + 'delegate
pub fn normalize_validate<'delegate, I: Iterator<Item = char> + 'delegate>( &'delegate self, iter: I, ) -> impl Iterator<Item = char> + 'delegate
See the method of the same name in icu_normalizer
for the
exact semantics.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Adapter
impl RefUnwindSafe for Adapter
impl !Send for Adapter
impl !Sync for Adapter
impl Unpin for Adapter
impl UnwindSafe for Adapter
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