Package akka.stream.scaladsl
Class WireTap<T>
- java.lang.Object
-
- akka.stream.stage.GraphStageWithMaterializedValue<S,NotUsed>
-
- akka.stream.stage.GraphStage<FanOutShape2<T,T,T>>
-
- akka.stream.scaladsl.WireTap<T>
-
- All Implemented Interfaces:
Graph<FanOutShape2<T,T,T>,NotUsed>
public final class WireTap<T> extends GraphStage<FanOutShape2<T,T,T>>
Fan-out the stream to two output streams - a 'main' and a 'tap' one. Each incoming element is emitted to the 'main' output; elements are also emitted to the 'tap' output if there is demand; otherwise they are dropped.'''Emits when''' element is available and demand exists from the 'main' output; the element will also be sent to the 'tap' output if there is demand.
'''Backpressures when''' the 'main' output backpressures
'''Completes when''' upstream completes
'''Cancels when''' the 'main' output cancels
-
-
Constructor Summary
Constructors Constructor Description WireTap()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static <T> WireTap<T>
apply()
GraphStageLogic
createLogic(Attributes inheritedAttributes)
Inlet<T>
in()
Attributes
initialAttributes()
Outlet<T>
outMain()
Outlet<T>
outTap()
FanOutShape2<T,T,T>
shape()
The shape of a graph is all that is externally visible: its inlets and outlets.java.lang.String
toString()
-
Methods inherited from class akka.stream.stage.GraphStage
createLogicAndMaterializedValue
-
Methods inherited from class akka.stream.stage.GraphStageWithMaterializedValue
createLogicAndMaterializedValue, traversalBuilder, withAttributes
-
-
-
-
Method Detail
-
initialAttributes
public Attributes initialAttributes()
- Overrides:
initialAttributes
in classGraphStageWithMaterializedValue<FanOutShape2<T,T,T>,NotUsed>
-
shape
public FanOutShape2<T,T,T> shape()
Description copied from interface:Graph
The shape of a graph is all that is externally visible: its inlets and outlets.- Returns:
- (undocumented)
-
createLogic
public GraphStageLogic createLogic(Attributes inheritedAttributes)
- Specified by:
createLogic
in classGraphStage<FanOutShape2<T,T,T>>
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
-