public class JcrLockManager extends Object implements LockManager
JcrLockManager
...Modifier | Constructor and Description |
---|---|
protected |
JcrLockManager(SessionImpl session) |
Modifier and Type | Method and Description |
---|---|
void |
addLockToken(String lt)
Delegates this call to
WorkspaceManager.addLockToken(String) . |
Lock |
getLock(String absPath) |
String[] |
getLockTokens()
Returns the lock tokens present on the
SessionInfo this
manager has been created with. |
boolean |
holdsLock(String absPath) |
boolean |
isLocked(String absPath) |
Lock |
lock(String absPath,
boolean isDeep,
boolean isSessionScoped,
long timeoutHint,
String ownerInfo) |
void |
removeLockToken(String lt)
If the lock addressed by the token is session-scoped, this method will
throw a LockException, such as defined by JSR170 v.1.0.1 for
Session.removeLockToken(String) .Otherwise the call is delegated to WorkspaceManager.removeLockToken(String) . |
void |
unlock(String absPath) |
protected JcrLockManager(SessionImpl session)
public Lock getLock(String absPath) throws LockException, RepositoryException
getLock
in interface LockManager
LockException
RepositoryException
LockManager.getLock(String)
public boolean isLocked(String absPath) throws RepositoryException
isLocked
in interface LockManager
RepositoryException
LockManager.isLocked(String)
public boolean holdsLock(String absPath) throws RepositoryException
holdsLock
in interface LockManager
RepositoryException
LockManager.holdsLock(String)
public Lock lock(String absPath, boolean isDeep, boolean isSessionScoped, long timeoutHint, String ownerInfo) throws RepositoryException
lock
in interface LockManager
RepositoryException
LockManager.lock(String, boolean, boolean, long, String)
public void unlock(String absPath) throws LockException, RepositoryException
unlock
in interface LockManager
LockException
RepositoryException
LockManager.unlock(String)
public String[] getLockTokens() throws RepositoryException
SessionInfo
this
manager has been created with.getLockTokens
in interface LockManager
RepositoryException
LockManager.getLockTokens()
public void addLockToken(String lt) throws LockException, RepositoryException
WorkspaceManager.addLockToken(String)
.
If this succeeds this method will inform all locks stored in the local
map in order to give them the chance to update their lock information.addLockToken
in interface LockManager
LockException
RepositoryException
LockManager.addLockToken(String)
public void removeLockToken(String lt) throws LockException, RepositoryException
Session.removeLockToken(String)
.WorkspaceManager.removeLockToken(String)
.
All locks stored in the local lock map are notified by the removed
token in order have them updated their lock information.removeLockToken
in interface LockManager
LockException
RepositoryException
LockManager.removeLockToken(String)
Copyright © 2004–2024 The Apache Software Foundation. All rights reserved.