public class PessimisticLockingPolicy
extends java.lang.Object
implements java.lang.Cloneable, java.io.Serializable
Description: This policy is used to configure bean level pessimistic locking feature. It is set on the CMPPolicy instance of the ClassDescriptor Note that bean is not pessimistic locked in the following scenarios:
Responsibilities:
CMPPolicy
,
Serialized FormModifier and Type | Field and Description |
---|---|
protected short |
lockingMode |
Constructor and Description |
---|
PessimisticLockingPolicy() |
Modifier and Type | Method and Description |
---|---|
java.lang.Object |
clone()
INTERNAL:
Clone the policy
|
short |
getLockingMode()
PUBLIC:
Return locking mode.
|
void |
setLockingMode(short mode)
PUBLIC:
Set locking mode.
|
public short getLockingMode()
public void setLockingMode(short mode)
short
- mode must be value of ObjectLevelReadQuery.LOCK or ObjectLevelReadQuery.LOCK_NOWAITpublic java.lang.Object clone()
clone
in class java.lang.Object