org.apache.jackrabbit.rmi.client
Class ClientLock

java.lang.Object
  extended by org.apache.jackrabbit.rmi.client.ClientObject
      extended by org.apache.jackrabbit.rmi.client.ClientLock
All Implemented Interfaces:
Lock

public class ClientLock
extends ClientObject
implements Lock

Local adapter for the JCR-RMI RemoteLock interface. This class makes a remote lock locally available using the JCR Lock interface.

See Also:
Lock, RemoteLock

Constructor Summary
ClientLock(Session session, RemoteLock remote, LocalAdapterFactory factory)
          Creates a local adapter for the given remote lock.
 
Method Summary
 String getLockOwner()
          
 String getLockToken()
          
 Node getNode()
          
 long getSecondsRemaining()
          
 boolean isDeep()
          
 boolean isLive()
          
 boolean isLockOwningSession()
          
 boolean isSessionScoped()
          
 void refresh()
          
 
Methods inherited from class org.apache.jackrabbit.rmi.client.ClientObject
getFactory, getItem, getNode, getNodeTypeArray
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ClientLock

public ClientLock(Session session,
                  RemoteLock remote,
                  LocalAdapterFactory factory)
Creates a local adapter for the given remote lock.

Parameters:
session - current session
remote - remote lock
factory - local adapter factory
Method Detail

getNode

public Node getNode()

Specified by:
getNode in interface Lock

getLockOwner

public String getLockOwner()

Specified by:
getLockOwner in interface Lock

isDeep

public boolean isDeep()

Specified by:
isDeep in interface Lock

getLockToken

public String getLockToken()

Specified by:
getLockToken in interface Lock

isLive

public boolean isLive()
               throws RepositoryException

Specified by:
isLive in interface Lock
Throws:
RepositoryException

refresh

public void refresh()
             throws RepositoryException

Specified by:
refresh in interface Lock
Throws:
RepositoryException

isSessionScoped

public boolean isSessionScoped()

Specified by:
isSessionScoped in interface Lock

getSecondsRemaining

public long getSecondsRemaining()
                         throws RepositoryException

Specified by:
getSecondsRemaining in interface Lock
Throws:
RepositoryException

isLockOwningSession

public boolean isLockOwningSession()

Specified by:
isLockOwningSession in interface Lock


Copyright © 2011-2013 Adobe Systems Incorporated. All Rights Reserved.