class DeformedClientLeaseMapWrapper extends AbstractLeaseMap
Provides hooks for synchronization and data associated with each
client lease while allowing us to use
LeaseRenewalManager. Objects of this class are
returned by createLeaseMap calls made on
ClientLeaseWrapper objects that are deformed.
ClientLeaseWrapper| Modifier and Type | Field and Description |
|---|---|
private static long |
serialVersionUID |
map, mapLock| Constructor and Description |
|---|
DeformedClientLeaseMapWrapper(ClientLeaseWrapper lease,
long duration)
Create a DeformedClientLeaseMapWrapper.
|
| Modifier and Type | Method and Description |
|---|---|
void |
cancelAll()
Cancels all leases in the LeaseMap.
|
boolean |
canContainKey(Object key)
Returns true if the given object is a Lease which can be renewed
and cancelled in a batch with other leases in the map.
|
private void |
renewAl() |
void |
renewAll()
Renews all leases in the LeaseMap, using their current values as
the renewal durations.
|
checkKey, checkValue, clear, containsKey, containsValue, entrySet, equals, get, hashCode, isEmpty, keySet, put, putAll, remove, size, valuesclone, finalize, getClass, notify, notifyAll, toString, wait, wait, waitcompute, computeIfAbsent, computeIfPresent, forEach, getOrDefault, merge, putIfAbsent, remove, replace, replace, replaceAllprivate static final long serialVersionUID
DeformedClientLeaseMapWrapper(ClientLeaseWrapper lease, long duration)
lease - a Wrapper for the lease that wants to be renewed.
May be deformed.duration - the duration to associate with leasepublic void cancelAll()
LeaseMappublic void renewAll()
throws LeaseMapException,
RemoteException
LeaseMapLeaseMapExceptionRemoteExceptionprivate void renewAl()
throws LeaseMapException,
RemoteException
LeaseMapExceptionRemoteExceptionpublic boolean canContainKey(Object key)
LeaseMapkey - an object that should be a leaseLease.canBatch(net.jini.core.lease.Lease)Copyright 2007-2013, multiple authors.
Licensed under the Apache License, Version 2.0, see the NOTICE file for attributions.