Trait ChainAugmenter

Source
pub trait ChainAugmenter<'a, A: Augmenter> {
    // Required method
    fn chain_augmenter(
        self,
        augmenter: &A,
    ) -> impl Iterator<Item = SegmentedToken<'a>>;
}
Expand description

Allows easily applying an Augmenter to an iterator of tokens.

It can be used for augmentation and normalization processing steps.

It can be used on any iterator that has SegmentedToken as its item.

Required Methods§

Source

fn chain_augmenter( self, augmenter: &A, ) -> impl Iterator<Item = SegmentedToken<'a>>

Process the iterator using an augmenter or normlizer

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.

Implementors§

Source§

impl<'a, A: Augmenter + 'a, I: Iterator<Item = SegmentedToken<'a>>> ChainAugmenter<'a, A> for I
where Self: 'a,