Expand description
Push-based stream combinators. Push-based stream combinators for dataflow pipelines.
This module provides push-based operators that mirror the pull-based operators in the parent module, but work in the opposite direction: items are pushed into a pipeline rather than pulled from it.
Re-exports§
pub use demux_var::DemuxVar;variadicspub use demux_var::PushVariadic;variadicspub use demux_var::demux_var;variadics
Modules§
Structs§
- Fanout
- Push combinator that clones each item and pushes to both downstream pushes.
- Filter
- Push combinator that only pushes items matching a predicate.
- Filter
Map - Push combinator that both filters and maps items.
- FlatMap
- Push combinator that maps each item to an iterator and pushes each element.
- Flat
MapStream - Push combinator that maps each item to a stream and pushes each element downstream.
- Flatten
- Push combinator that flattens iterable items by pushing each element downstream.
- Flatten
Stream - Push combinator that flattens stream items by polling each stream and pushing elements downstream.
- ForEach
- Terminal push combinator that consumes each item with a closure.
- Inspect
- Push combinator that calls a closure on each item for side effects before pushing downstream.
- Map
- Push combinator that transforms each item with a closure before pushing downstream.
- Persist
alloc - Special push operator for the
persistoperator. - Resolve
Futures - Push operator that receives futures, queues them, and pushes their resolved outputs downstream.
- Sink
- Adapter that wraps a
futures_sink::Sinkto implement thePushtrait. - Sink
Compat - Adapter that wraps a
Pushto implement theSinktrait. - Unzip
- Push combinator that splits
(A, B)items into two separate downstream pushes. - VecPush
alloc - Terminal push operator that collects items into a
Vec.
Enums§
Traits§
- Push
- The
Pushtrait represents a push-based pipeline that items can be sent into.
Functions§
- fanout
- Creates a
Fanoutpush that clones each item and sends to both downstream pushes. - filter
- Creates a
Filterpush that filters items based on a predicate. - filter_
map - Creates a
FilterMappush that filters and maps items in one step. - flat_
map - Creates a
FlatMappush that maps each item to an iterator and flattens the results. - flat_
map_ stream - Creates a
FlatMapStreampush that maps each item to a stream and flattens the results. - flatten
- Creates a
Flattenpush that flattens items that are iterators. - flatten_
stream - Creates a
FlattenStreampush that flattens items that are streams. - for_
each - Creates a
ForEachterminal push that consumes each item with a function. - inspect
- Creates an
Inspectpush that inspects each item without modifying it. - map
- Creates a
Mappush that applies a function to each item. - persist_
state alloc - Creates a
Persistusing an externalVecstate for buffering items. - resolve_
futures_ state - Creates a
ResolveFuturespush that resolves futures and sends their outputs. - sink
- Creates a
Sinkpush that wraps afutures_sink::Sink. - sink_
compat - Creates a
SinkCompatadapter that wraps aPushand implementsfutures_sink::Sink. - unzip
- Creates an
Unzippush that splits tuple items into two separate pushes. - vec_
push alloc - Creates a
VecPushthat pushes items into the givenVec.