public interface CDOLockState
As an individual lock is always owned by view, which in turn is owned by a session, the methods on this interface
return instances of CDOLockOwner
which carry that information.
Object
oneway - - lockedObject, CDOLockOwner
oneway - - writeLockOwner, CDOLockOwner
oneway - - writeOptionOwnerCDOLockOwner
- - readLockOwnersModifier and Type | Field and Description |
---|---|
static int |
DEPTH_INFINITE |
static int |
DEPTH_NONE |
Modifier and Type | Method and Description |
---|---|
Object |
getLockedObject()
Gets a unique identifier for the object that is locked; typically a
CDOID or a CDOIDAndBranch ,
depending on whether branching support is enabled or not |
Set<CDOLockOwner> |
getReadLockOwners() |
CDOLockOwner |
getWriteLockOwner() |
CDOLockOwner |
getWriteOptionOwner() |
boolean |
isLocked(IRWLockManager.LockType lockType,
CDOLockOwner lockOwner,
boolean others)
If the 'others' argument is
false , this method returns true if this lock is currently
held by the requesting CDOView, false otherwise. |
static final int DEPTH_NONE
static final int DEPTH_INFINITE
Object getLockedObject()
CDOID
or a CDOIDAndBranch
,
depending on whether branching support is enabled or notboolean isLocked(IRWLockManager.LockType lockType, CDOLockOwner lockOwner, boolean others)
false
, this method returns true
if this lock is currently
held by the requesting CDOView, false
otherwise.
If the 'others' argument is true
, this method returns true
if this lock is currently held
by another view (i.e. any view different from the requesting one), false
otherwise.
Set<CDOLockOwner> getReadLockOwners()
CDOLockOwner getWriteLockOwner()
CDOLockOwner getWriteOptionOwner()
Copyright (c) 2014 Eike Stepper (Berlin, Germany) and others.
All rights reserved. This program and the accompanying materials are made available under the terms of the Eclipse Public License v1.0 which accompanies this distribution, and is available at http://www.eclipse.org/legal/epl-v10.html