Class Sink<TIn, TMat>
A Sink<TIn, TMat> is a set of stream processing steps that has one open input. Can be used as a Reactive.Streams.ISubscriber<T>
Inherited Members
Namespace: Akka.Streams.Dsl
Assembly: Akka.Streams.dll
Syntax
public sealed class Sink<TIn, TMat> : IGraph<SinkShape<TIn>, TMat>, IGraph<SinkShape<TIn>>
Type Parameters
| Name | Description |
|---|---|
| TIn | TBD |
| TMat | TBD |
Constructors
| Edit this page View SourceSink(IModule)
TBD
Declaration
public Sink(IModule module)
Parameters
| Type | Name | Description |
|---|---|---|
| IModule | module | TBD |
Properties
| Edit this page View SourceModule
TBD
Declaration
public IModule Module { get; }
Property Value
| Type | Description |
|---|---|
| IModule |
Shape
TBD
Declaration
public SinkShape<TIn> Shape { get; }
Property Value
| Type | Description |
|---|---|
| SinkShape<TIn> |
Methods
| Edit this page View SourceAddAttributes(Attributes)
Add the given attributes to this Sink<TIn, TMat>. Further calls to WithAttributes(Attributes) will not remove these attributes. Note that this operation has no effect on an empty Flow (because the attributes apply only to the contained processing stages).
Declaration
public Sink<TIn, TMat> AddAttributes(Attributes attributes)
Parameters
| Type | Name | Description |
|---|---|---|
| Attributes | attributes | TBD |
Returns
| Type | Description |
|---|---|
| Sink<TIn, TMat> | TBD |
Async()
Put an asynchronous boundary around this Sink.
Declaration
public Sink<TIn, TMat> Async()
Returns
| Type | Description |
|---|---|
| Sink<TIn, TMat> | TBD |
ContraMap<TIn2>(Func<TIn2, TIn>)
Transform this Sink by applying a function to each incoming upstream element before it is passed to the Sink
Backpressures when original Sink backpressures
Cancels when original Sink backpressures
Declaration
public Sink<TIn2, TMat> ContraMap<TIn2>(Func<TIn2, TIn> function)
Parameters
| Type | Name | Description |
|---|---|---|
| Func<TIn2, TIn> | function | TBD |
Returns
| Type | Description |
|---|---|
| Sink<TIn2, TMat> | TBD |
Type Parameters
| Name | Description |
|---|---|
| TIn2 | TBD |
MapMaterializedValue<TMat2>(Func<TMat, TMat2>)
Transform only the materialized value of this Sink, leaving all other properties as they were.
Declaration
public Sink<TIn, TMat2> MapMaterializedValue<TMat2>(Func<TMat, TMat2> fn)
Parameters
| Type | Name | Description |
|---|---|---|
| Func<TMat, TMat2> | fn | TBD |
Returns
| Type | Description |
|---|---|
| Sink<TIn, TMat2> | TBD |
Type Parameters
| Name | Description |
|---|---|
| TMat2 | TBD |
Named(string)
Add a name attribute to this Sink.
Declaration
public Sink<TIn, TMat> Named(string name)
Parameters
| Type | Name | Description |
|---|---|---|
| string | name | TBD |
Returns
| Type | Description |
|---|---|
| Sink<TIn, TMat> | TBD |
PreMaterialize(IMaterializer)
Materializes this Sink immediately.
Useful for when you need a materialized value of a Sink when handing it out to someone to materialize it for you.
Declaration
public (TMat, Sink<TIn, NotUsed>) PreMaterialize(IMaterializer materializer)
Parameters
| Type | Name | Description |
|---|---|---|
| IMaterializer | materializer | The materializer. |
Returns
| Type | Description |
|---|---|
| (TMat, Sink<TIn, NotUsed>) | A tuple containing the (1) materialized value and (2) a new Sink that can be used to consume elements from the newly materialized Sink. |
RunWith<TMat2>(IGraph<SourceShape<TIn>, TMat2>, IMaterializer)
Connect this Sink<TIn, TMat> to a Source<TOut, TMat> and run it. The returned value is the materialized value of the Source<TOut, TMat>, e.g. the Reactive.Streams.ISubscriber<T>.
Declaration
public TMat2 RunWith<TMat2>(IGraph<SourceShape<TIn>, TMat2> source, IMaterializer materializer)
Parameters
| Type | Name | Description |
|---|---|---|
| IGraph<SourceShape<TIn>, TMat2> | source | TBD |
| IMaterializer | materializer | TBD |
Returns
| Type | Description |
|---|---|
| TMat2 | TBD |
Type Parameters
| Name | Description |
|---|---|
| TMat2 | TBD |
ToString()
TBD
Declaration
public override string ToString()
Returns
| Type | Description |
|---|---|
| string | TBD |
Overrides
| Edit this page View SourceWithAttributes(Attributes)
Change the attributes of this Sink<TIn, TMat> to the given ones and seal the list of attributes. This means that further calls will not be able to remove these attributes, but instead add new ones. Note that this operation has no effect on an empty Flow (because the attributes apply only to the contained processing stages).
Declaration
public Sink<TIn, TMat> WithAttributes(Attributes attributes)
Parameters
| Type | Name | Description |
|---|---|---|
| Attributes | attributes | TBD |
Returns
| Type | Description |
|---|---|
| Sink<TIn, TMat> | TBD |
Edit this page