public class ClientLockProxy extends ClientProxy implements ILock
ILock.name| Constructor and Description |
|---|
ClientLockProxy(String serviceName,
String objectId,
ClientContext context) |
| Modifier and Type | Method and Description |
|---|---|
void |
forceUnlock() |
Object |
getKey()
Deprecated.
|
int |
getLockCount() |
long |
getRemainingLeaseTime() |
protected ClientMessage |
invokeOnPartition(ClientMessage req) |
protected <T> T |
invokeOnPartition(ClientMessage clientMessage,
long invocationTimeoutSeconds) |
protected <T> ClientDelegatingFuture<T> |
invokeOnPartitionAsync(ClientMessage clientMessage,
ClientMessageDecoder clientMessageDecoder) |
protected <T> T |
invokeOnPartitionInterruptibly(ClientMessage clientMessage) |
protected <T> T |
invokeOnPartitionInterruptibly(ClientMessage clientMessage,
long invocationTimeoutSeconds) |
boolean |
isLocked() |
boolean |
isLockedByCurrentThread() |
void |
lock() |
void |
lock(long leaseTime,
TimeUnit timeUnit) |
void |
lockInterruptibly() |
Condition |
newCondition() |
ICondition |
newCondition(String name) |
protected void |
onInitialize()
Called when proxy is created.
|
String |
toString() |
boolean |
tryLock() |
boolean |
tryLock(long timeout,
TimeUnit unit) |
boolean |
tryLock(long timeout,
TimeUnit unit,
long leaseTime,
TimeUnit leaseUnit) |
void |
unlock() |
deregisterListener, destroy, destroyLocally, destroyRemotely, equals, getClient, getConnectedServerVersion, getContext, getDistributedObjectName, getId, getName, getPartitionKey, getSerializationService, getServiceName, hashCode, invoke, invoke, invokeOnAddress, invokeOnPartition, invokeOnPartitionInterruptibly, onDestroy, onShutdown, postDestroy, preDestroy, registerListener, setContext, toData, toObjectclone, finalize, getClass, notify, notifyAll, wait, wait, waitdestroy, getName, getPartitionKey, getServiceNamepublic ClientLockProxy(String serviceName, String objectId, ClientContext context)
@Deprecated public Object getKey()
public boolean isLockedByCurrentThread()
isLockedByCurrentThread in interface ILockpublic int getLockCount()
getLockCount in interface ILockpublic long getRemainingLeaseTime()
getRemainingLeaseTime in interface ILockpublic void forceUnlock()
forceUnlock in interface ILockpublic ICondition newCondition(String name)
newCondition in interface ILockpublic void lockInterruptibly()
throws InterruptedException
lockInterruptibly in interface LockInterruptedExceptionpublic boolean tryLock()
public boolean tryLock(long timeout,
TimeUnit unit)
throws InterruptedException
tryLock in interface ILocktryLock in interface LockInterruptedExceptionpublic boolean tryLock(long timeout,
TimeUnit unit,
long leaseTime,
TimeUnit leaseUnit)
throws InterruptedException
tryLock in interface ILockInterruptedExceptionpublic void unlock()
public Condition newCondition()
newCondition in interface ILocknewCondition in interface Lockprotected void onInitialize()
ClientProxyprotected ClientMessage invokeOnPartition(ClientMessage req)
protected <T> T invokeOnPartitionInterruptibly(ClientMessage clientMessage) throws InterruptedException
InterruptedExceptionprotected <T> ClientDelegatingFuture<T> invokeOnPartitionAsync(ClientMessage clientMessage, ClientMessageDecoder clientMessageDecoder)
protected <T> T invokeOnPartition(ClientMessage clientMessage, long invocationTimeoutSeconds)
protected <T> T invokeOnPartitionInterruptibly(ClientMessage clientMessage, long invocationTimeoutSeconds) throws InterruptedException
InterruptedExceptionCopyright © 2020 Hazelcast, Inc.. All Rights Reserved.