Package com.googlecode.objectify
Enum TxnType
- All Implemented Interfaces:
Serializable
,Comparable<TxnType>
,java.lang.constant.Constable
Just like the EJB options. See http://docs.oracle.com/javaee/6/api/javax/ejb/TransactionAttributeType.html
- Author:
- Jeff Schnitzer invalid input: '<'[email protected]>
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
Enum ConstantDescriptionRequire that there must already be a transaction running.Require that there must NOT be a transaction running.Execute the work without a transaction, pausing an existing transaction if there is one.Use the existing transaction (if present), or start a new transaction if not.Start a new transaction, pausing the old one.Inherits previous transaction state. -
Method Summary
-
Enum Constant Details
-
MANDATORY
Require that there must already be a transaction running. If no transaction, throw an IllegalStateException. -
NEVER
Require that there must NOT be a transaction running. If there is, throw an IllegalStateException. -
NOT_SUPPORTED
Execute the work without a transaction, pausing an existing transaction if there is one. -
REQUIRED
Use the existing transaction (if present), or start a new transaction if not. -
REQUIRES_NEW
Start a new transaction, pausing the old one. -
SUPPORTS
Inherits previous transaction state.
-
-
Method Details
-
values
Returns 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
-
valueOf
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
-