Package akka.stream.impl.fusing
Class MapError<T>
- java.lang.Object
-
- akka.stream.stage.GraphStageWithMaterializedValue<S,NotUsed>
-
- akka.stream.stage.GraphStage<FlowShape<T,T>>
-
- akka.stream.impl.fusing.GraphStages.SimpleLinearGraphStage<T>
-
- akka.stream.impl.fusing.MapError<T>
-
- All Implemented Interfaces:
Graph<FlowShape<T,T>,NotUsed>
,java.io.Serializable
,scala.Equals
,scala.Product
,scala.Serializable
public final class MapError<T> extends GraphStages.SimpleLinearGraphStage<T> implements scala.Product, scala.Serializable
Maps error with the provided function if it is defined for an error or, otherwise, passes it on unchanged.While similar to
Recover
this operator can be used to transform an error signal to a different one *without* logging it as an error in the process. So in that sense it is NOT exactly equivalent torecover(t => throw t2)
since recover would log thet2
error.- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description MapError(scala.PartialFunction<java.lang.Throwable,java.lang.Throwable> f)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static <T> MapError<T>
apply(scala.PartialFunction<java.lang.Throwable,java.lang.Throwable> f)
boolean
canEqual(java.lang.Object x$1)
<T> MapError<T>
copy(scala.PartialFunction<java.lang.Throwable,java.lang.Throwable> f)
<T> scala.PartialFunction<java.lang.Throwable,java.lang.Throwable>
copy$default$1()
GraphStageLogic
createLogic(Attributes attr)
boolean
equals(java.lang.Object x$1)
scala.PartialFunction<java.lang.Throwable,java.lang.Throwable>
f()
int
hashCode()
int
productArity()
java.lang.Object
productElement(int x$1)
scala.collection.Iterator<java.lang.Object>
productIterator()
java.lang.String
productPrefix()
java.lang.String
toString()
static <T> scala.Option<scala.PartialFunction<java.lang.Throwable,java.lang.Throwable>>
unapply(MapError<T> x$0)
-
Methods inherited from class akka.stream.impl.fusing.GraphStages.SimpleLinearGraphStage
in, out, shape
-
Methods inherited from class akka.stream.stage.GraphStage
createLogicAndMaterializedValue
-
Methods inherited from class akka.stream.stage.GraphStageWithMaterializedValue
createLogicAndMaterializedValue, initialAttributes, traversalBuilder, withAttributes
-
-
-
-
Method Detail
-
apply
public static <T> MapError<T> apply(scala.PartialFunction<java.lang.Throwable,java.lang.Throwable> f)
-
unapply
public static <T> scala.Option<scala.PartialFunction<java.lang.Throwable,java.lang.Throwable>> unapply(MapError<T> x$0)
-
f
public scala.PartialFunction<java.lang.Throwable,java.lang.Throwable> f()
-
createLogic
public GraphStageLogic createLogic(Attributes attr)
- Specified by:
createLogic
in classGraphStage<FlowShape<T,T>>
-
copy
public <T> MapError<T> copy(scala.PartialFunction<java.lang.Throwable,java.lang.Throwable> f)
-
copy$default$1
public <T> scala.PartialFunction<java.lang.Throwable,java.lang.Throwable> copy$default$1()
-
productPrefix
public java.lang.String productPrefix()
- Specified by:
productPrefix
in interfacescala.Product
-
productArity
public int productArity()
- Specified by:
productArity
in interfacescala.Product
-
productElement
public java.lang.Object productElement(int x$1)
- Specified by:
productElement
in interfacescala.Product
-
productIterator
public scala.collection.Iterator<java.lang.Object> productIterator()
- Specified by:
productIterator
in interfacescala.Product
-
canEqual
public boolean canEqual(java.lang.Object x$1)
- Specified by:
canEqual
in interfacescala.Equals
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classjava.lang.Object
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
equals
public boolean equals(java.lang.Object x$1)
- Specified by:
equals
in interfacescala.Equals
- Overrides:
equals
in classjava.lang.Object
-
-