Enum Class MetricsCollector.StreamTerminalOutcome
java.lang.Object
java.lang.Enum<MetricsCollector.StreamTerminalOutcome>
com.pyranid.MetricsCollector.StreamTerminalOutcome
- All Implemented Interfaces:
Serializable, Comparable<MetricsCollector.StreamTerminalOutcome>, Constable
- Enclosing interface:
MetricsCollector
public static enum MetricsCollector.StreamTerminalOutcome
extends Enum<MetricsCollector.StreamTerminalOutcome>
Terminal outcome for an opened stream.
- Since:
- 4.2.0
- Author:
- Mark Allen
-
Nested Class Summary
Nested classes/interfaces inherited from class Enum
Enum.EnumDesc<E> -
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionThe caller-provided stream callback failed.Stream iteration reached the end of the result set and cleanup completed without an iteration or callback failure.The stream was closed before all rows were consumed.Result-set iteration failed while the stream was open.The stream failed before it opened. -
Method Summary
Modifier and TypeMethodDescriptionReturns the enum constant of this class with the specified name.values()Returns an array containing the constants of this enum class, in the order they are declared.Methods inherited from class Enum
compareTo, describeConstable, equals, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
-
Enum Constant Details
-
COMPLETED_NORMALLY
Stream iteration reached the end of the result set and cleanup completed without an iteration or callback failure. -
EARLY_CLOSE
The stream was closed before all rows were consumed. -
CALLBACK_FAILURE
The caller-provided stream callback failed. -
ITERATION_FAILURE
Result-set iteration failed while the stream was open. -
OPEN_FAILURE
The stream failed before it opened.Pyranid normally reports this through
MetricsCollector.didFailToOpenStream(StatementContext, DatabaseType, Duration, Throwable)instead ofMetricsCollector.didCloseStream(StatementContext, StreamTerminalOutcome, Long, Duration, Throwable).
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (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:
IllegalArgumentException- if this enum class has no constant with the specified nameNullPointerException- if the argument is null
-