|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.jackrabbit.jcr2spi.lock.DefaultLockManager
public class DefaultLockManager
DefaultLockManager...
| Constructor Summary | |
|---|---|
DefaultLockManager()
|
|
| Method Summary | |
|---|---|
void |
addLockToken(java.lang.String lt)
Invoked by a session to inform that a lock token has been added. |
void |
checkLock(NodeState nodeState)
Check whether the given node state is locked by somebody else than the current session. |
javax.jcr.lock.Lock |
getLock(NodeState nodeState)
Returns the Lock object that applies to a node. |
java.lang.String[] |
getLockTokens()
|
boolean |
isLocked(NodeState nodeState)
Returns true if this node is locked either as a result
of a lock held by this node or by a deep lock on a node above this
node; otherwise returns false. |
javax.jcr.lock.Lock |
lock(NodeState nodeState,
boolean isDeep,
boolean isSessionScoped)
Lock a node. |
void |
removeLockToken(java.lang.String lt)
Invoked by a session to inform that a lock token has been removed. |
void |
unlock(NodeState nodeState)
Removes the lock on a node. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public DefaultLockManager()
| Method Detail |
|---|
public javax.jcr.lock.Lock lock(NodeState nodeState,
boolean isDeep,
boolean isSessionScoped)
throws javax.jcr.lock.LockException,
javax.jcr.RepositoryException
LockManager
lock in interface LockManagerisDeep - whether the lock applies to this node onlyisSessionScoped - whether the lock is session scoped
javax.jcr.lock.LockException - if this node already is locked, or some descendant
node is locked and isDeep is true
javax.jcr.RepositoryExceptionNode.lock(boolean, boolean)
public void unlock(NodeState nodeState)
throws javax.jcr.lock.LockException,
javax.jcr.RepositoryException
LockManager
unlock in interface LockManagerjavax.jcr.lock.LockException - if this node is not locked or the session does not
have the correct lock token
javax.jcr.RepositoryExceptionNode.unlock()
public javax.jcr.lock.Lock getLock(NodeState nodeState)
throws javax.jcr.lock.LockException,
javax.jcr.RepositoryException
LockManager
getLock in interface LockManagerjavax.jcr.lock.LockException - if this node is not locked
javax.jcr.RepositoryExceptionNode.getLock()
public boolean isLocked(NodeState nodeState)
throws javax.jcr.RepositoryException
LockManagertrue if this node is locked either as a result
of a lock held by this node or by a deep lock on a node above this
node; otherwise returns false.
isLocked in interface LockManagertrue if this node is locked either as a result
of a lock held by this node or by a deep lock on a node above this
node; otherwise returns false
javax.jcr.RepositoryExceptionNode.isLocked()
public void checkLock(NodeState nodeState)
throws javax.jcr.lock.LockException,
javax.jcr.RepositoryException
LockManager
checkLock in interface LockManagerjavax.jcr.lock.LockException - if write access to the specified node is not allowed
javax.jcr.RepositoryException - if some other error occurspublic java.lang.String[] getLockTokens()
getLockTokens in interface LockManagerpublic void addLockToken(java.lang.String lt)
LockManager
addLockToken in interface LockManagerlt - added lock tokenpublic void removeLockToken(java.lang.String lt)
LockManager
removeLockToken in interface LockManagerlt - removed lock token
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||