Contents
- Sink
- Contramap <A, B> (K<Sink, B> fb, Func<A, B> f)
- Divide <A, B, C> (Func<A, (B Left, C Right)> f, K<Sink, B> fb, K<Sink, C> fc)
- Conquer <A> ()
- Lose <A> (Func<A, Void> f)
- Route <A, B, C> (Func<A, Either<B, C>> f, K<Sink, B> fb, K<Sink, C> fc)
- Sink <A>
- Post (A value)
- Complete ()
- Fail (Error Error)
- Contramap <B> (Func<B, A> f)
- Combine (Sink<A> rhs)
- Combine <X, B> (Func<X, (A Left, B Right)> f, Sink<B> rhs)
- + (Sink<A> lhs, Sink<A> rhs)
- Empty
- Void
- ToConsumerT <M> ()
- ToConsumer <RT> ()
- SinkExtensions
Entry point to a channel. Sinkes receive values and propagate them through the
channel they're attached to. The behaviour depends on the Buffer
type they
were created with.
Parameters
type | A | Value type |
Properties
Methods
method IO<Unit> Post (A value) Source #
Post a value to the Sink
Raises Errors.NoSpaceInSink
if the Sink is full or closed.
Parameters
param | value | Value to post |
returns | IO computation that represents the posting |
method Sink<A> Combine (Sink<A> rhs) Source #
Combine two Sinkes: lhs
and rhs
into a single Sink that takes incoming
values and then posts the to the lhs
and rhs
Sinkes.
method Sink<X> Combine <X, B> (Func<X, (A Left, B Right)> f, Sink<B> rhs) Source #
Combine two Sinkes: lhs
and rhs
into a single Sink that takes incoming
values, maps them to an (A, B)
tuple, and the posts the first and second
elements to the lhs
and rhs
Sinkes.
method ConsumerT<A, M, Unit> ToConsumerT <M> () Source #
Convert the Sink
to a ConsumerT
pipe component
Parameters
type | M | Monad to lift (must support |
returns |
|
method Consumer<RT, A, Unit> ToConsumer <RT> () Source #
Convert the Sink
to a Consumer
pipe component
Parameters
returns |
|