Trait rs_transducers::Reducing [] [src]

pub trait Reducing<I, O, E> {
    type Item;
    fn step(&mut self, value: I) -> Result<StepResult, E>;
    fn complete(&mut self) -> Result<(), E>;

    fn init(&mut self) { ... }
}

Defines a reducing function from I to O with step errors of E

Associated Types

The type of each value after the reducing function

Required Methods

Each step, may fail TODO: the return type to contain an indicator of early termination

Transducers must call the underlying complete

Provided Methods

Transducers must call the underlying init TODO: may not be required at all. Not currently used by any implementation

Implementors