public class ServerLock extends ServerObject implements RemoteLock
Lock
interface.
This class makes a local lock available as an RMI service using
the RemoteLock
interface.Lock
,
RemoteLock
,
Serialized Formref
Constructor and Description |
---|
ServerLock(Lock lock,
RemoteAdapterFactory factory)
Creates a remote adapter for the given local lock.
|
Modifier and Type | Method and Description |
---|---|
String |
getLockOwner()
Remote version of the
Lock.getLockOwner() method. |
String |
getLockToken()
Remote version of the
Lock.getLockToken() method. |
RemoteNode |
getNode()
Remote version of the
Lock.getNode() method. |
long |
getSecondsRemaining()
Remote version of the
Lock.getSecondsRemaining() () Lock.getSecondsRemaining()} method. |
boolean |
isDeep()
Remote version of the
Lock.isDeep() method. |
boolean |
isLive()
Remote version of the
Lock.isLive() method. |
boolean |
isLockOwningSession()
Remote version of the
Lock.isLockOwningSession() () Lock.isLockOwningSession()} method. |
boolean |
isSessionScoped()
Remote version of the
Lock.isSessionScoped() () Lock.isSessionScoped()} method. |
void |
refresh()
Remote version of the
Lock.refresh() method. |
getFactory, getRemoteItem, getRemoteNode, getRemoteNodeTypeArray, getRepositoryException, getSerialValue, getSerialValues
clone, exportObject, exportObject, exportObject, unexportObject
getClientHost, getLog, setLog
public ServerLock(Lock lock, RemoteAdapterFactory factory) throws RemoteException
lock
- local lockRemoteException
- on RMI errorspublic RemoteNode getNode() throws RemoteException
Lock.getNode()
method.getNode
in interface RemoteLock
RemoteException
- on RMI errorspublic String getLockOwner() throws RemoteException
Lock.getLockOwner()
method.getLockOwner
in interface RemoteLock
RemoteException
- on RMI errorspublic boolean isDeep() throws RemoteException
Lock.isDeep()
method.isDeep
in interface RemoteLock
true
if the lock is deep,
false
otherwiseRemoteException
- on RMI errorspublic String getLockToken() throws RemoteException
Lock.getLockToken()
method.getLockToken
in interface RemoteLock
RemoteException
- on RMI errorspublic boolean isLive() throws RepositoryException, RemoteException
Lock.isLive()
method.isLive
in interface RemoteLock
true
if the lock is live,
false
otherwiseRepositoryException
- on repository errorsRemoteException
- on RMI errorspublic void refresh() throws RepositoryException, RemoteException
Lock.refresh()
method.refresh
in interface RemoteLock
RepositoryException
- on repository errorsRemoteException
- on RMI errorspublic boolean isSessionScoped() throws RemoteException
Lock.isSessionScoped()
() Lock.isSessionScoped()} method.isSessionScoped
in interface RemoteLock
true
if the lock is live,
false
otherwiseRemoteException
- on RMI errorspublic long getSecondsRemaining() throws RepositoryException, RemoteException
Lock.getSecondsRemaining()
() Lock.getSecondsRemaining()} method.getSecondsRemaining
in interface RemoteLock
RepositoryException
- on repository errorsRemoteException
- on RMI errorspublic boolean isLockOwningSession() throws RemoteException
Lock.isLockOwningSession()
() Lock.isLockOwningSession()} method.isLockOwningSession
in interface RemoteLock
boolean
.RemoteException
- on RMI errorsCopyright © 2004–2021 The Apache Software Foundation. All rights reserved.