Package org.apache.jackrabbit.jcr2spi
Class JcrLockManager
- java.lang.Object
-
- org.apache.jackrabbit.jcr2spi.JcrLockManager
-
- All Implemented Interfaces:
LockManager
public class JcrLockManager extends Object implements LockManager
JcrLockManager...
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedJcrLockManager(SessionImpl session)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddLockToken(String lt)Delegates this call toWorkspaceManager.addLockToken(String).LockgetLock(String absPath)String[]getLockTokens()Returns the lock tokens present on theSessionInfothis manager has been created with.booleanholdsLock(String absPath)booleanisLocked(String absPath)Locklock(String absPath, boolean isDeep, boolean isSessionScoped, long timeoutHint, String ownerInfo)voidremoveLockToken(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 forSession.removeLockToken(String).
Otherwise the call is delegated toWorkspaceManager.removeLockToken(String).voidunlock(String absPath)
-
-
-
Constructor Detail
-
JcrLockManager
protected JcrLockManager(SessionImpl session)
-
-
Method Detail
-
getLock
public Lock getLock(String absPath) throws LockException, RepositoryException
- Specified by:
getLockin interfaceLockManager- Throws:
LockExceptionRepositoryException- See Also:
LockManager.getLock(String)
-
isLocked
public boolean isLocked(String absPath) throws RepositoryException
- Specified by:
isLockedin interfaceLockManager- Throws:
RepositoryException- See Also:
LockManager.isLocked(String)
-
holdsLock
public boolean holdsLock(String absPath) throws RepositoryException
- Specified by:
holdsLockin interfaceLockManager- Throws:
RepositoryException- See Also:
LockManager.holdsLock(String)
-
lock
public Lock lock(String absPath, boolean isDeep, boolean isSessionScoped, long timeoutHint, String ownerInfo) throws RepositoryException
- Specified by:
lockin interfaceLockManager- Throws:
RepositoryException- See Also:
LockManager.lock(String, boolean, boolean, long, String)
-
unlock
public void unlock(String absPath) throws LockException, RepositoryException
- Specified by:
unlockin interfaceLockManager- Throws:
LockExceptionRepositoryException- See Also:
LockManager.unlock(String)
-
getLockTokens
public String[] getLockTokens() throws RepositoryException
Returns the lock tokens present on theSessionInfothis manager has been created with.- Specified by:
getLockTokensin interfaceLockManager- Throws:
RepositoryException- See Also:
LockManager.getLockTokens()
-
addLockToken
public void addLockToken(String lt) throws LockException, RepositoryException
Delegates this call toWorkspaceManager.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.- Specified by:
addLockTokenin interfaceLockManager- Throws:
LockExceptionRepositoryException- See Also:
LockManager.addLockToken(String)
-
removeLockToken
public void removeLockToken(String lt) throws LockException, RepositoryException
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 forSession.removeLockToken(String).
Otherwise the call is delegated toWorkspaceManager.removeLockToken(String). All locks stored in the local lock map are notified by the removed token in order have them updated their lock information.- Specified by:
removeLockTokenin interfaceLockManager- Throws:
LockExceptionRepositoryException- See Also:
LockManager.removeLockToken(String)
-
-