Token

Trait Token 

Source
pub trait Token:
    Copy
    + Ord
    + Measure
    + PartialEnum
    + RangePartialOrd
    + Bounded {
    // Required methods
    fn all() -> RangeSet<Self>;
    fn len(&self) -> usize;
    fn is_one(len: Self::Len) -> bool;
}

Required Methods§

Source

fn all() -> RangeSet<Self>

Source

fn len(&self) -> usize

Returns the (byte) length of the token.

Source

fn is_one(len: Self::Len) -> bool

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementations on Foreign Types§

Source§

impl Token for char

Source§

fn all() -> RangeSet<Self>

Source§

fn len(&self) -> usize

Source§

fn is_one(len: Self::Len) -> bool

Source§

impl Token for u8

Source§

fn all() -> RangeSet<Self>

Source§

fn len(&self) -> usize

Source§

fn is_one(len: Self::Len) -> bool

Implementors§