public class ClientIdGeneratorProxy extends ClientProxy implements IdGenerator
IdGenerator.name| Constructor and Description |
|---|
ClientIdGeneratorProxy(String serviceName,
String objectId,
ClientContext context,
IAtomicLong blockGenerator) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
init(long id)
Tries to initialize this
IdGenerator instance with the given ID. |
long |
newId()
Generates and returns a cluster-wide unique ID.
|
protected void |
onDestroy()
Called before proxy is destroyed.
|
String |
toString() |
deregisterListener, destroy, destroyLocally, destroyRemotely, equals, getClient, getConnectedServerVersion, getContext, getDistributedObjectName, getId, getName, getPartitionKey, getSerializationService, getServiceName, hashCode, invoke, invoke, invokeOnAddress, invokeOnPartition, invokeOnPartitionInterruptibly, onInitialize, onShutdown, postDestroy, preDestroy, registerListener, setContext, toData, toObjectclone, finalize, getClass, notify, notifyAll, wait, wait, waitdestroy, getName, getPartitionKey, getServiceNamepublic ClientIdGeneratorProxy(String serviceName, String objectId, ClientContext context, IAtomicLong blockGenerator)
public boolean init(long id)
IdGeneratorIdGenerator instance with the given ID.
The next generated ID will be 1 greater than the supplied ID.
init in interface IdGeneratortrue if initialization succeeded, false otherwise.public long newId()
IdGeneratornewId in interface IdGeneratorprotected void onDestroy()
ClientProxyonDestroy in class ClientProxyCopyright © 2020 Hazelcast, Inc.. All Rights Reserved.