static final class FiddlerLeaseMap.ConstrainableFiddlerLeaseMap extends FiddlerLeaseMap
FiddlerLeaseMap
.FiddlerLeaseMap.ConstrainableFiddlerLeaseMap
Modifier and Type | Field and Description |
---|---|
private static Method |
cancelMethod |
private static Method[] |
canContainKeyMethodMapArray
In order to determine if a given lease will be accepted by this
map as a "legal" key value, the method
canContainKey
must verify that the corresponding methods of the initial
lease used to create this map and the lease input to
canContainKey have equivalent constraints. |
private MethodConstraints |
methodConstraints
Client constraints placed on this proxy (may be
null ). |
private static Method[] |
methodMapArray |
private static Method |
renewMethod |
server, serverID
map
Modifier | Constructor and Description |
---|---|
private |
FiddlerLeaseMap.ConstrainableFiddlerLeaseMap(Fiddler server,
FiddlerLease lease,
long duration,
MethodConstraints methodConstraints)
Constructs a new
ConstrainableFiddlerLeaseMap
instance. |
Modifier and Type | Method and Description |
---|---|
boolean |
canContainKey(Object key)
Examines the input parameter to determine if that parameter will
be accepted or rejected by this map as a "legal" key value.
|
private static Fiddler |
constrainServer(Fiddler server,
MethodConstraints constraints)
Returns a copy of the given server proxy having the client method
constraints that result after the specified method mapping is
applied to the given client method constraints.
|
cancelAll, createLeaseMap, renewAll
checkKey, checkValue, clear, containsKey, containsValue, entrySet, equals, get, hashCode, isEmpty, keySet, put, putAll, remove, size, values
private static final Method renewMethod
private static final Method cancelMethod
private static final Method[] methodMapArray
private static final Method[] canContainKeyMethodMapArray
canContainKey
must verify that the corresponding methods of the initial
lease used to create this map and the lease input to
canContainKey
have equivalent constraints. The
array defined here contains the set of methods whose constraints
will be compared in canContainKey
.private MethodConstraints methodConstraints
null
).private FiddlerLeaseMap.ConstrainableFiddlerLeaseMap(Fiddler server, FiddlerLease lease, long duration, MethodConstraints methodConstraints)
ConstrainableFiddlerLeaseMap
instance.
For a description of all but the methodConstraints
argument (provided below), refer to the description for the
constructor of this class' super class.
methodConstraints
- the client method constraints to place on
this proxy (may be null
).public boolean canContainKey(Object key)
This method will return true if the key
parameter is
the type of lease which can be "batch-wise" renewed and cancelled
along with all of the other leases in the map.
For this implementation of the service, two leases can be
batched (placed in the same service-specific instance of
LeaseMap
) if those leases satisfy the following
conditions:
Lease
implementation
canContainKey
in interface LeaseMap
canContainKey
in class FiddlerLeaseMap
key
- reference to the object that this method examines to
determine if this map will accept or reject it as a keytrue
if this map will accept the
key
parameter, false
otherwiseLease.canBatch(net.jini.core.lease.Lease)
,
LeaseMap.canContainKey(java.lang.Object)
private static Fiddler constrainServer(Fiddler server, MethodConstraints constraints)
Copyright 2007-2013, multiple authors.
Licensed under the Apache License, Version 2.0, see the NOTICE file for attributions.