Package com.mongodb.event
Enum ConnectionCheckOutFailedEvent.Reason
- java.lang.Object
-
- java.lang.Enum<ConnectionCheckOutFailedEvent.Reason>
-
- com.mongodb.event.ConnectionCheckOutFailedEvent.Reason
-
- All Implemented Interfaces:
Serializable
,Comparable<ConnectionCheckOutFailedEvent.Reason>
- Enclosing class:
- ConnectionCheckOutFailedEvent
public static enum ConnectionCheckOutFailedEvent.Reason extends Enum<ConnectionCheckOutFailedEvent.Reason>
An enumeration of the reasons checking out a connection failed
-
-
Enum Constant Summary
Enum Constants Enum Constant Description CONNECTION_ERROR
The connection check out attempt experienced an error while setting up a new connectionPOOL_CLOSED
The pool was previously closed and cannot provide new connectionsTIMEOUT
The connection check out attempt exceeded the specific timeoutUNKNOWN
Reason unknown
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static ConnectionCheckOutFailedEvent.Reason
valueOf(String name)
Returns the enum constant of this type with the specified name.static ConnectionCheckOutFailedEvent.Reason[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
POOL_CLOSED
public static final ConnectionCheckOutFailedEvent.Reason POOL_CLOSED
The pool was previously closed and cannot provide new connections
-
TIMEOUT
public static final ConnectionCheckOutFailedEvent.Reason TIMEOUT
The connection check out attempt exceeded the specific timeout
-
CONNECTION_ERROR
public static final ConnectionCheckOutFailedEvent.Reason CONNECTION_ERROR
The connection check out attempt experienced an error while setting up a new connection
-
UNKNOWN
public static final ConnectionCheckOutFailedEvent.Reason UNKNOWN
Reason unknown
-
-
Method Detail
-
values
public static ConnectionCheckOutFailedEvent.Reason[] 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 (ConnectionCheckOutFailedEvent.Reason c : ConnectionCheckOutFailedEvent.Reason.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static ConnectionCheckOutFailedEvent.Reason valueOf(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:
IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is null
-
-