com.ibm.commerce.context.content.locking
Interface LockingPolicy
-
- All Known Implementing Classes:
- NoLockingPolicy, SingleUserLockingPolicy, TaskGroupLockingPolicy, TaskLockingPolicy, WorkspaceLockingPolicy
public interface LockingPolicy
This is an interface that describes the content management locking policy. A locking policy is a service object that offers a set of API to determine why a managed resource is locked. It is based on some session or environment variables. Different deployment strategies will have different requirements. For this reason, this interface defines the set of services offered where specialized instances of this service are created to cover different locking requirements.
-
-
Field Summary
Fields Modifier and Type Field and Description static java.lang.String
COPYRIGHT
IBM copyright notice field.
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method and Description boolean
canActivityModifyManagedResource(ActivityToken activityToken, LockData lockData)
This method determines whether the activity has permission to modify the resource.boolean
isManagedResourcedLocked(LockData managedResourceLockData, LockData environmentLockData)
This method determines whether the managed resource is locked and thus whether the current operation should be completed.
-
-
-
Field Detail
-
COPYRIGHT
static final java.lang.String COPYRIGHT
IBM copyright notice field.- See Also:
- Constant Field Values
-
-
Method Detail
-
canActivityModifyManagedResource
boolean canActivityModifyManagedResource(ActivityToken activityToken, LockData lockData)
This method determines whether the activity has permission to modify the resource. Otherwise it is considered untouchable to the current activity.- Parameters:
activityToken
- The current activity.lockData
- The lock data of the resource.- Returns:
- This method returns whether the current activity can modify the object.
-
isManagedResourcedLocked
boolean isManagedResourcedLocked(LockData managedResourceLockData, LockData environmentLockData)
This method determines whether the managed resource is locked and thus whether the current operation should be completed. This is based on the current managed resource lock data and the current lock data that represents the current environment or session state.- Parameters:
managedResourceLockData
- The current lock data associated with the managed resource.environmentLockData
- The lock data representation of the environment associated with the current operation.- Returns:
- This method returns whether the managed resource is considered locked and whether the current operation should be performed based on the current environment context.
-
-