Package org.apache.tomcat.dbcp.pool2
Enum PooledObjectState
- All Implemented Interfaces:
- Serializable,- Comparable<PooledObjectState>,- java.lang.constant.Constable
Provides all possible states of a 
PooledObject.- Since:
- 2.0
- 
Nested Class SummaryNested classes/interfaces inherited from class java.lang.EnumEnum.EnumDesc<E extends Enum<E>>
- 
Enum Constant SummaryEnum ConstantsEnum ConstantDescriptionDeemed abandoned, to be invalidated.In use.In the queue, currently being tested for possible eviction.Not in the queue, currently being tested for possible eviction.In the queue, not in use.Failed maintenance (e.g. eviction test or validation) and will be / has been destroyedReturning to the pool.In the queue, currently being validated.Not in queue, currently being validated.Not in queue, currently being validated.
- 
Method SummaryModifier and TypeMethodDescriptionstatic PooledObjectStateReturns the enum constant of this type with the specified name.static PooledObjectState[]values()Returns an array containing the constants of this enum type, in the order they are declared.
- 
Enum Constant Details- 
IDLEIn the queue, not in use.
- 
ALLOCATEDIn use.
- 
EVICTIONIn the queue, currently being tested for possible eviction.
- 
EVICTION_RETURN_TO_HEADNot in the queue, currently being tested for possible eviction. An attempt to borrow the object was made while being tested which removed it from the queue. It should be returned to the head of the queue once eviction testing completes.TODO: Consider allocating object and ignoring the result of the eviction test. 
- 
VALIDATIONIn the queue, currently being validated.
- 
VALIDATION_PREALLOCATEDNot in queue, currently being validated. The object was borrowed while being validated and since testOnBorrow was configured, it was removed from the queue and pre-allocated. It should be allocated once validation completes.
- 
VALIDATION_RETURN_TO_HEADNot in queue, currently being validated. An attempt to borrow the object was made while previously being tested for eviction which removed it from the queue. It should be returned to the head of the queue once validation completes.
- 
INVALIDFailed maintenance (e.g. eviction test or validation) and will be / has been destroyed
- 
ABANDONEDDeemed abandoned, to be invalidated.
- 
RETURNINGReturning to the pool.
 
- 
- 
Method Details- 
valuesReturns an array containing the constants of this enum type, in the order they are declared.- Returns:
- an array containing the constants of this enum type, in the order they are declared
 
- 
valueOfReturns 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 name
- NullPointerException- if the argument is null
 
 
-