Skip to main content

Jig

Trait Jig 

Source
pub trait Jig<In> {
    type Out;

    // Required method
    fn run(&self, input: In) -> Self::Out;
}
Expand description

One step in a jigs pipeline. Any Fn(In) -> Out automatically implements this trait, so plain functions, closures, and #[jig]-annotated functions can all be chained with .then(...).

Required Associated Types§

Source

type Out

The value produced by running this jig.

Required Methods§

Source

fn run(&self, input: In) -> Self::Out

Execute the jig on the given input.

Implementors§

Source§

impl<In, Out, F> Jig<In> for F
where F: Fn(In) -> Out,

Source§

type Out = Out