public static enum Transaction.CLOSE_BEHAVIOR extends Enum<Transaction.CLOSE_BEHAVIOR> implements Consumer<Transaction>
Transaction.onClose(Consumer)
. The semantics of these behaviors must be examined in
the context of the implementation. In most cases, these behaviors will be applied as {ThreadLocal
}.Enum Constant and Description |
---|
COMMIT
Commit the transaction when
Transaction.close() is called. |
MANUAL
Throw an exception if the current transaction is open when
Transaction.close() is called. |
ROLLBACK
Rollback the transaction when
Transaction.close() is called. |
Modifier and Type | Method and Description |
---|---|
static Transaction.CLOSE_BEHAVIOR |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static Transaction.CLOSE_BEHAVIOR[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final Transaction.CLOSE_BEHAVIOR COMMIT
Transaction.close()
is called.public static final Transaction.CLOSE_BEHAVIOR ROLLBACK
Transaction.close()
is called.public static final Transaction.CLOSE_BEHAVIOR MANUAL
Transaction.close()
is called.public static Transaction.CLOSE_BEHAVIOR[] values()
for (Transaction.CLOSE_BEHAVIOR c : Transaction.CLOSE_BEHAVIOR.values()) System.out.println(c);
public static Transaction.CLOSE_BEHAVIOR valueOf(String name)
name
- the name of the enum constant to be returned.IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is nullCopyright © 2013–2023 Apache Software Foundation. All rights reserved.