Struct ClassUnicode
struct ClassUnicode { ... }
A Unicode character class.
Fields
span: SpanThe span of this class.
negated: boolWhether this class is negated or not.
Note: be careful when using this attribute. This specifically refers to whether the class is written as
\por\P, where the latter isnegated = true. However, it also possible to write something like\P{scx!=Katakana}which is actually equivalent to\p{scx=Katakana}and is therefore not actually negated even thoughnegated = truehere. To test whether this class is truly negated or not, use theis_negatedmethod.kind: ClassUnicodeKindThe kind of Unicode class.
Implementations
impl ClassUnicode
fn is_negated(self: &Self) -> boolReturns true if this class has been negated.
Note that this takes the Unicode op into account, if it's present. e.g.,
is_negatedfor\P{scx!=Katakana}will returnfalse.
impl Clone for ClassUnicode
fn clone(self: &Self) -> ClassUnicode
impl Debug for ClassUnicode
fn fmt(self: &Self, f: &mut Formatter<'_>) -> Result
impl Eq for ClassUnicode
impl Freeze for ClassUnicode
impl PartialEq for ClassUnicode
fn eq(self: &Self, other: &ClassUnicode) -> bool
impl RefUnwindSafe for ClassUnicode
impl Send for ClassUnicode
impl StructuralPartialEq for ClassUnicode
impl Sync for ClassUnicode
impl Unpin for ClassUnicode
impl UnsafeUnpin for ClassUnicode
impl UnwindSafe for ClassUnicode
impl<T> Any for ClassUnicode
fn type_id(self: &Self) -> TypeId
impl<T> Borrow for ClassUnicode
fn borrow(self: &Self) -> &T
impl<T> BorrowMut for ClassUnicode
fn borrow_mut(self: &mut Self) -> &mut T
impl<T> CloneToUninit for ClassUnicode
unsafe fn clone_to_uninit(self: &Self, dest: *mut u8)
impl<T> From for ClassUnicode
fn from(t: T) -> TReturns the argument unchanged.
impl<T> ToOwned for ClassUnicode
fn to_owned(self: &Self) -> Tfn clone_into(self: &Self, target: &mut T)
impl<T, U> Into for ClassUnicode
fn into(self: Self) -> UCalls
U::from(self).That is, this conversion is whatever the implementation of
[From]<T> for Uchooses to do.
impl<T, U> TryFrom for ClassUnicode
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
impl<T, U> TryInto for ClassUnicode
fn try_into(self: Self) -> Result<U, <U as TryFrom<T>>::Error>