Interface Lockable<PK>
- All Superinterfaces:
BusinessObject<PK>
Lockable is the interface a
BusinessObject must implement to be used for locking.
If an owner is set, the business object is locked by him or her. Unlock will remove an owner.- Since:
- Nuclos 4.10
-
Method Summary
Modifier and TypeMethodDescriptionvoidlock()Lock this business object by setting the current user as owner.voidLock this business object by setting the given owner.voidunlock()Unlock this business object by removing the owner.voidUnlock this business object after commit by removing the owner.Methods inherited from interface org.nuclos.api.businessobject.BusinessObject
getEntity, getEntityUid, getId, getVersion, isDelete, isInsert, isUpdate
-
Method Details
-
lock
Lock this business object by setting the current user as owner. Uses a new transaction but will not increment the version!- Throws:
BusinessException
-
lock
Lock this business object by setting the given owner. Uses a new transaction but will not increment the version!- Parameters:
ownerId-- Throws:
BusinessException
-
unlock
Unlock this business object by removing the owner. Uses a new transaction but will not increment the version!- Throws:
BusinessException
-
unlockAfterCommit
Unlock this business object after commit by removing the owner. Uses a new transaction but will not increment the version!- Throws:
BusinessException
-