Package io.reactivex.rxjava3.parallel
Enum ParallelFailureHandling
- java.lang.Object
-
- java.lang.Enum<ParallelFailureHandling>
-
- io.reactivex.rxjava3.parallel.ParallelFailureHandling
-
- All Implemented Interfaces:
BiFunction<java.lang.Long,java.lang.Throwable,ParallelFailureHandling>
,java.io.Serializable
,java.lang.Comparable<ParallelFailureHandling>
public enum ParallelFailureHandling extends java.lang.Enum<ParallelFailureHandling> implements BiFunction<java.lang.Long,java.lang.Throwable,ParallelFailureHandling>
Enumerations for handling failure within a parallel operator.History: 2.0.8 - experimental
- Since:
- 2.2
-
-
Constructor Summary
Constructors Modifier Constructor Description private
ParallelFailureHandling()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description ParallelFailureHandling
apply(java.lang.Long t1, java.lang.Throwable t2)
Calculate a value based on the input values.static ParallelFailureHandling
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name.static ParallelFailureHandling[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
STOP
public static final ParallelFailureHandling STOP
The current rail is stopped and the error is dropped.
-
ERROR
public static final ParallelFailureHandling ERROR
The current rail is stopped and the error is signalled.
-
SKIP
public static final ParallelFailureHandling SKIP
The current value and error is ignored and the rail resumes with the next item.
-
RETRY
public static final ParallelFailureHandling RETRY
Retry the current value.
-
-
Method Detail
-
values
public static ParallelFailureHandling[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (ParallelFailureHandling c : ParallelFailureHandling.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static ParallelFailureHandling valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
java.lang.IllegalArgumentException
- if this enum type has no constant with the specified namejava.lang.NullPointerException
- if the argument is null
-
apply
public ParallelFailureHandling apply(java.lang.Long t1, java.lang.Throwable t2)
Description copied from interface:BiFunction
Calculate a value based on the input values.- Specified by:
apply
in interfaceBiFunction<java.lang.Long,java.lang.Throwable,ParallelFailureHandling>
- Parameters:
t1
- the first valuet2
- the second value- Returns:
- the result value
-
-