Package ratpack.stream
Interface StreamMapper<U,D>
-
- Type Parameters:
U- the type of item emitted from upstreamD- the type of item to emit downstream (i.e. post transform)
public interface StreamMapper<U,D>Fundamentally transforms a stream.- Since:
- 1.4
- See Also:
Streams.streamMap(Publisher, StreamMapper)
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description WriteStream<U>map(Subscription subscription, WriteStream<D> downstream)A transform step in aPublisherchain.
-
-
-
Method Detail
-
map
WriteStream<U> map(Subscription subscription, WriteStream<D> downstream) throws java.lang.Exception
A transform step in aPublisherchain.- Parameters:
subscription- the upstream subscriptiondownstream- the downstream to write to- Returns:
- a write stream that receives signals from upstream
- Throws:
java.lang.Exception- any error in establishing the mapping
-
-