Enum ClassAsciiKind

pub enum ClassAsciiKind

The available ASCII character classes.

Variants

Alnum

[0-9A-Za-z]

Alpha

[A-Za-z]

Ascii

[\x00-\x7F]

Blank

[ \t]

Cntrl

[\x00-\x1F\x7F]

Digit

[0-9]

Graph

[!-~]

Lower

[a-z]

Print

[ -~]

Punct

[!-/:-@\[-`{-~]

Space

[\t\n\v\f\r ]

Upper

[A-Z]

Word

[0-9A-Za-z_]

Xdigit

[0-9A-Fa-f]

Implementations

impl ClassAsciiKind

fn from_name(name: &str) -> Option<ClassAsciiKind>

Return the corresponding ClassAsciiKind variant for the given name.

The name given should correspond to the lowercase version of the variant name. e.g., cntrl is the name for ClassAsciiKind::Cntrl.

If no variant with the corresponding name exists, then None is returned.

Trait Implementations

impl Clone for ClassAsciiKind

fn clone(&self) -> Self

impl Debug for ClassAsciiKind

fn fmt(&self, f: &mut Formatter<'_>) -> Result

impl Eq for ClassAsciiKind

impl PartialEq for ClassAsciiKind

fn eq(&self, other: &Self) -> bool

impl StructuralPartialEq for ClassAsciiKind

Auto Trait Implementations

impl Freeze for ClassAsciiKind

impl RefUnwindSafe for ClassAsciiKind

impl Send for ClassAsciiKind

impl Sync for ClassAsciiKind

impl Unpin for ClassAsciiKind

impl UnsafeUnpin for ClassAsciiKind

impl UnwindSafe for ClassAsciiKind

Blanket Implementations

impl<T> Any for ClassAsciiKind where T: 'static + ?Sized,

fn type_id(&self) -> TypeId

impl<T> Borrow<T> for ClassAsciiKind where T: ?Sized,

fn borrow(&self) -> &T

impl<T> BorrowMut<T> for ClassAsciiKind where T: ?Sized,

fn borrow_mut(&mut self) -> &mut T

impl<T> CloneToUninit for ClassAsciiKind where T: Clone,

unsafe fn clone_to_uninit(&self, dest: *mut u8)

impl<T> From<T> for ClassAsciiKind

fn from(t: T) -> T

Returns the argument unchanged.

impl<T> ToOwned for ClassAsciiKind where T: Clone,

type Owned = T;
fn to_owned(&self) -> T
fn clone_into(&self, target: &mut T)

impl<T, U> Into<U> for ClassAsciiKind where U: From<T>,

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of [From]<T> for U chooses to do.

impl<T, U> TryFrom<U> for ClassAsciiKind where U: Into<T>,

type Error = never;
fn try_from(value: U) -> Result<T, never>

impl<T, U> TryInto<U> for ClassAsciiKind where U: TryFrom<T>,

type Error = <U as TryFrom<T>>::Error;
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>