Oracle Fusion Middleware Java API Reference for Oracle TopLink
11g Release 1 (11.1.1)

B32476-03

oracle.toplink.descriptors
Class FieldsLockingPolicy

java.lang.Object
  extended by oracle.toplink.descriptors.FieldsLockingPolicy
All Implemented Interfaces:
java.io.Serializable, java.lang.Cloneable, oracle.toplink.internal.descriptors.OptimisticLockingPolicy
Direct Known Subclasses:
AllFieldsLockingPolicy, ChangedFieldsLockingPolicy, SelectedFieldsLockingPolicy

public abstract class FieldsLockingPolicy
extends java.lang.Object
implements oracle.toplink.internal.descriptors.OptimisticLockingPolicy

Purpose: An abstract superclass of some implementations of the OptimisticLockingPolicy interface. All of the subclasses of this class implement OptimisticLocking based on mapped fields in the object. These fields are only compared and not modified. Any modification (incrementing etc..) must be handled by the application.

Since:
TopLink 2.1
See Also:
AllFieldsLockingPolicy, ChangedFieldsLockingPolicy, SelectedFieldsLockingPolicy, Serialized Form

Constructor Summary
FieldsLockingPolicy()
          Create a new field locking policy.
 
Method Summary
 boolean isCascaded()
          Return true if the policy uses cascade locking.
 boolean isStoredInCache()
          Return true if the lock value is stored in the cache.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

FieldsLockingPolicy

public FieldsLockingPolicy()
Create a new field locking policy. A field locking policy is based on locking on a subset of fields by comparing with their previous values to detect field-level collisions. Note: the unit of work must be used for all updates when using field locking.

Method Detail

isStoredInCache

public boolean isStoredInCache()
Return true if the lock value is stored in the cache.

Specified by:
isStoredInCache in interface oracle.toplink.internal.descriptors.OptimisticLockingPolicy

isCascaded

public boolean isCascaded()
Return true if the policy uses cascade locking. Currently, not supported on this policy at this time.

Specified by:
isCascaded in interface oracle.toplink.internal.descriptors.OptimisticLockingPolicy

Copyright © 1998, 2010, Oracle. All Rights Reserved.