pub trait Class<T = char>: MapSource {
// Required methods
fn classify<'a>(
&self,
set: &'a RangeSet<T>,
) -> Self::Map<Mown<'a, RangeSet<T>>>;
fn next_class(&self, token: &T) -> Self;
}Expand description
Token class.
Required Methods§
Sourcefn classify<'a>(&self, set: &'a RangeSet<T>) -> Self::Map<Mown<'a, RangeSet<T>>>
fn classify<'a>(&self, set: &'a RangeSet<T>) -> Self::Map<Mown<'a, RangeSet<T>>>
Classify the given token set.
The output is a partition of the input set, where each member of the partition is associated to a different class.
fn next_class(&self, token: &T) -> Self
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.