ParsableTransformation

Trait ParsableTransformation 

Source
pub trait ParsableTransformation<O> {
    type Input;

    // Required method
    fn transform(input: Self::Input) -> Result<O, ParseError<'static>>;
}
Expand description

Generic fallible transformation between two types for parsing

See the documentation for TransformParser for more details.

Required Associated Types§

Source

type Input

The type that will be transformed by the implementation if this trait (Self::Input -> O).

Required Methods§

Source

fn transform(input: Self::Input) -> Result<O, ParseError<'static>>

Performs the transformation.

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§