Red Hat Data Grid HotRod C++ Client
7.2.0
|
#include <CacheClientListener.h>
Public Member Functions | |
std::string | getName () |
std::string | getVersion () |
std::string | getProtocolVersion () |
V * | get (const K &key) |
std::map< std::shared_ptr< K >, std::shared_ptr< V > > | getAll (const std::set< K > &keySet) |
std::future< V * > | getAsync (const K &key, std::function< V *(V *)> success=nullptr, std::function< V *(std::exception &)> fail=nullptr) |
V * | put (const K &key, const V &val, uint64_t lifespan=0, uint64_t maxIdle=0) |
V * | put (const K &key, const V &val, uint64_t lifespan, TimeUnit lifespanUnit) |
V * | put (const K &key, const V &val, uint64_t lifespan, TimeUnit lifespanUnit, uint64_t maxIdle, TimeUnit maxIdleUnit) |
std::future< V * > | putAsync (const K &key, const V &val, uint64_t lifespan=0, uint64_t maxIdle=0, std::function< V *(V *)> success=nullptr, std::function< V *(std::exception &)> fail=nullptr) |
std::future< V * > | putAsync (const K &key, const V &val, uint64_t lifespan, TimeUnit lifespanUnit, std::function< V *(V *)> success=nullptr, std::function< V *(std::exception &)> fail=nullptr) |
std::future< V * > | putAsync (const K &key, const V &val, uint64_t lifespan, TimeUnit lifespanUnit, uint64_t maxIdle, TimeUnit maxIdleUnit, std::function< V *(V *)> success=nullptr, std::function< V *(std::exception &)> fail=nullptr) |
V * | putIfAbsent (const K &key, const V &val, uint64_t lifespan=0, uint64_t maxIdle=0) |
V * | putIfAbsent (const K &key, const V &val, uint64_t lifespan, TimeUnit lifespanUnit) |
V * | putIfAbsent (const K &key, const V &val, uint64_t lifespan, TimeUnit lifespanUnit, uint64_t maxIdle, TimeUnit maxIdleUnit) |
std::future< V * > | putIfAbsentAsync (const K &key, const V &val, uint64_t lifespan=0, uint64_t maxIdle=0, std::function< V *(V *)> success=nullptr, std::function< V *(std::exception &)> fail=nullptr) |
std::future< V * > | putIfAbsentAsync (const K &key, const V &val, uint64_t lifespan, TimeUnit lifespanUnit, std::function< V *(V *)> success=nullptr, std::function< V *(std::exception &)> fail=nullptr) |
std::future< V * > | putIfAbsentAsync (const K &key, const V &val, uint64_t lifespan, TimeUnit lifespanUnit, uint64_t maxIdle, TimeUnit maxIdleUnit, std::function< V *(V *)> success=nullptr, std::function< V *(std::exception &)> fail=nullptr) |
void | putAll (const std::map< K, V > &map, uint64_t lifespan=0, uint64_t maxIdle=0) |
void | putAll (const std::map< K, V > &map, uint64_t lifespan, TimeUnit lifespanUnit) |
void | putAll (const std::map< K, V > &map, uint64_t lifespan, TimeUnit lifespanUnit, uint64_t maxIdle, TimeUnit maxIdleUnit) |
std::future< void > | putAllAsync (const std::map< K, V > &map, uint64_t lifespan=0, uint64_t maxIdle=0, std::function< void()> success=nullptr, std::function< void(std::exception &)> fail=nullptr) |
std::future< void > | putAllAsync (const std::map< K, V > &map, uint64_t lifespan, TimeUnit lifespanUnit, std::function< void(void)> success=nullptr, std::function< void(std::exception &)> fail=nullptr) |
std::future< void > | putAllAsync (const std::map< K, V > &map, uint64_t lifespan, TimeUnit lifespanUnit, uint64_t maxIdle, TimeUnit maxIdleUnit, std::function< void(void)> success=nullptr, std::function< void(std::exception &)> fail=nullptr) |
V * | replace (const K &key, const V &val, uint64_t lifespan=0, uint64_t maxIdle=0) |
V * | replace (const K &key, const V &val, uint64_t lifespan, TimeUnit lifespanUnit) |
V * | replace (const K &key, const V &val, uint64_t lifespan, TimeUnit lifespanUnit, uint64_t maxIdle, TimeUnit maxIdleUnit) |
V * | replace (const K &key, const V &oldVal, const V &val, uint64_t lifespan=0, uint64_t maxIdle=0) |
V * | replace (const K &key, const V &oldVal, const V &val, uint64_t lifespan, TimeUnit lifespanUnit) |
V * | replace (const K &key, const V &oldVal, const V &val, uint64_t lifespan, TimeUnit lifespanUnit, uint64_t maxIdle, TimeUnit maxIdleUnit) |
std::future< V * > | replaceAsync (const K &key, const V &val, uint64_t lifespan=0, uint64_t maxIdle=0, std::function< V *(V *)> success=nullptr, std::function< V *(std::exception &)> fail=nullptr) |
std::future< V * > | replaceAsync (const K &key, const V &val, uint64_t lifespan, TimeUnit lifespanUnit, std::function< V *(V *)> success=nullptr, std::function< V *(std::exception &)> fail=nullptr) |
std::future< V * > | replaceAsync (const K &key, const V &val, uint64_t lifespan, TimeUnit lifespanUnit, uint64_t maxIdle, TimeUnit maxIdleUnit, std::function< V *(V *)> success=nullptr, std::function< V *(std::exception &)> fail=nullptr) |
std::future< V * > | replaceAsync (const K &key, const V &oldVal, const V &val, uint64_t lifespan=0, uint64_t maxIdle=0, std::function< V *(V *)> success=nullptr, std::function< V *(std::exception &)> fail=nullptr) |
std::future< V * > | replaceAsync (const K &key, const V &oldVal, const V &val, uint64_t lifespan, TimeUnit lifespanUnit, std::function< V *(V *)> success=nullptr, std::function< V *(std::exception &)> fail=nullptr) |
V * | remove (const K &key) |
std::future< V * > | removeAsync (const K &key, std::function< V *(V *)> success=nullptr, std::function< V *(std::exception &)> fail=nullptr) |
bool | containsKey (const K &key) |
bool | containsValue (const V &val) |
bool | replaceWithVersion (const K &key, const V &val, uint64_t version, uint64_t lifespan=0, uint64_t maxIdle=0) |
std::future< bool > | replaceWithVersionAsync (const K &key, const V &val, uint64_t version, uint64_t lifespan, uint64_t maxIdle, std::function< bool(bool)> success=nullptr, std::function< bool(std::exception &)> fail=nullptr) |
bool | removeWithVersion (const K &key, uint64_t version) |
std::future< bool > | removeWithVersionAsync (const K &key, uint64_t version, std::function< bool(bool)> success=nullptr, std::function< bool(std::exception &)> fail=nullptr) |
std::pair< std::shared_ptr< V >, VersionedValue > | getWithVersion (const K &key) |
std::pair< std::shared_ptr< V >, MetadataValue > | getWithMetadata (const K &key) |
std::map< std::shared_ptr< K >, std::shared_ptr< V > > | getBulk () |
std::map< std::shared_ptr< K >, std::shared_ptr< V > > | getBulk (int nrOfEntries) |
std::vector< unsigned char > | execute (const std::string &name, const std::map< std::string, std::string > &args) |
std::vector< unsigned char > | execute (const std::string &name, const std::map< std::vector< char >, std::vector< char > > &args) |
QueryResponse | query (const QueryRequest &qr) |
std::vector< unsigned char > | query (std::vector< unsigned char > qr, size_t size) |
std::set< std::pair< K, V > > | entrySet () |
std::set< std::shared_ptr< K > > | keySet () |
uint64_t | size () |
bool | isEmpty () |
std::vector< V > | values () |
std::map< std::string, std::string > | stats () |
void | clear () |
std::future< void > | clearAsync (std::function< void(void)> success=nullptr, std::function< void(std::exception &)> fail=nullptr) |
void | ping () |
void | addClientListener (ClientListener &clientListener, std::vector< std::vector< char > > filterFactoryParams, std::vector< std::vector< char > > converterFactoryParams, const std::function< void()> &recoveryCallback=nullptr) |
void | removeClientListener (ClientListener &clientListener) |
void | addContinuousQueryListener (ContinuousQueryListener< K, V > &cql) |
template<typename... Params> | |
void | addContinuousQueryListener (ContinuousQueryListener< K, V, Params... > &cql) |
template<typename... Params> | |
void | removeContinuousQueryListener (ContinuousQueryListener< Params... > &cql) |
CacheTopologyInfo | getCacheTopologyInfo () |
RemoteCache< K, V > & | withFlags (Flag flags) |
template<class M = JBossMarshaller> | |
RemoteExecution< M > | getRemoteExecution () |
RemoteCache (const RemoteCache &other) | |
RemoteCache< K, V > & | operator= (const RemoteCache &other) |
Protected Member Functions | |
RemoteCache () | |
Friends | |
class | RemoteCacheManager |
Provides remote reference to a cache residing on a Hot Rod server/cluster.
RemoteCache is intended to be similar to Infinispan Java RemoteCache interface as much as possible. Just like RemoteCache interface in its Java HotRod counterpart RemoteCache features:
New methods: Although some methods are very simila to Java Map interface, RemoteCache also adds new methods to optimize/reduce network traffic: e.g. versioned put operation.
Concurrency: implementations will support multi-threaded access.
Return values: previously existing values for certain methods are not returned, NULL is returned instead unless method is using fluent variant withFlags (see below).
Synthetic methods: aggregate methods are being implemented based on other Hot Rod operations. For example, putAll method is implemented using multiple individual puts. Therefore these methods are not atomic and that they are costly, e.g. as the number of network round-trips is not one, but the size of the added map.
It is possible change the default method behavior using Flag enum. For example:
RemoteCache cache = ...; std::auto_ptr<std::string> rv(cache.withFlags(FORCE_RETURN_VALUE).put(k,v));
In the previous example Flag enum FORCE_RETURN_VALUE will make the client to also return previously existing value associated with k
key. If this flag would not be present, RemoteCache would return (by default) NULL
. This is in order to avoid fetching a possibly large object from the remote server, which might not be needed.
|
inline |
|
inlineprotected |
|
inline |
Start client listener and register it on the server
clientListener | object defining the listener, filter and converter and the callback funcs |
filterFactoryParams | parameters for optional server filter setup |
converterFactoryParams | parameter for optional server converter setup |
recoveryCallback | function to be called if transport goes down |
|
inline |
Start a client listener on the specified query and register it on the server
cql | object defining the query to be observed |
|
inline |
Start a client listener on a query that returns projection or aggregate and register it on the server
cql | object defining the query to be observed |
|
inline |
Clears all entries in this cache
|
inline |
Asynchronous version of clear() See the synchronous doc for parameters not explained here
success | function to be executed on success |
fail | function to be executed if exceptions occur |
|
inline |
Returns true if this cache contains a key/value pair where the key is equal to a specified key.
key | the key |
|
inline |
Unsupported operation in this release of Hot Rod client. UnsupportedOperationException is thrown if his method is invoked.
|
inline |
Unsupported operation in this release of Hot Rod client. UnsupportedOperationException is thrown if his method is invoked.
|
inline |
Execute script on server
name | name of the script |
args | maps of (name,value) arguments |
|
inline |
Execute script on server
name | name of the script |
args | maps of (name,value) arguments |
|
inline |
Returns the value to which the specified key is mapped, or NULL if this cache contains no mapping for the key.
key | the key whose associated value is to be returned |
|
inline |
Returns a map of key,value pairs according to the set of keys passed in input
keySet | the set of the keys whose associated values are to be returned |
|
inline |
Asynchronous version of get. Executes function f when get() returns
See the synchronous doc for parameters not explained here
key | the key whose associated value is to be returned |
success | function to be executed on success |
fail | function to be executed if exceptions occur |
|
inline |
Unsupported operation in this release of Hot Rod client. UnsupportedOperationException is thrown if his method is invoked.
|
inline |
Returns nrOfEntries from a remote cache in map. TODO
|
inline |
|
inline |
Retrieves the name of the cache
|
inline |
Retrieves the protocol version
|
inline |
Get a remote execution context
|
inline |
Retrieves the version of Infinispan
|
inline |
Returns the std::pair with value and MetadataValue associated to the supplied key parameter or a default initialized std::pair if it doesn't exist
key | the key |
|
inline |
Returns the std::pair with value and VersionedValue associated with the supplied key parameter or a default initialized std::pair if it doesn't exist
key | the key |
|
inline |
Returns true if and only if this cache has no entries.
|
inline |
Returns all keys in the remote server. It'll invoke a command over the network each time this method is called. If the remote cache is a distributed cache, it will retrieve all of the keys from all nodes in the cluster. Please use with care for cache with large data set.
|
inline |
|
inline |
Pings remote cache on a Hot Rod server
|
inline |
Associates the specified value with the specified key in this cache.
If the cache previously contained a mapping for the key, the old value is replaced by the specified value.
If the return value of this operation will be ignored by the application, the user is strongly encouraged to use the IGNORE_RETURN_VALUES Flag when invoking this method in order to make it behave as efficiently as possible (i.e. avoiding needless remote or network calls).
key | key with which the specified value is to be associated |
val | value value to be associated with the specified key |
lifespan | the lifespan of this entry. A negative value is interpreted as unlimited lifespan |
maxIdle | the maximum amount of time this entry is allowed to be idle before it is considered as expired |
|
inline |
Associates the specified value with the specified key in this cache.
If the cache previously contained a mapping for the key, the old value is replaced by the specified value.
If the return value of this operation will be ignored by the application, the user is strongly encouraged to use the IGNORE_RETURN_VALUES Flag when invoking this method in order to make it behave as efficiently as possible (i.e. avoiding needless remote or network calls).
key | key with which the specified value is to be associated |
val | value value to be associated with the specified key |
lifespan | the lifespan of this entry. A negative value is interpreted as unlimited lifespan |
lifespanUnit | TimeUnit for the lifespan param |
|
inline |
Associates the specified value with the specified key in this cache.
If the cache previously contained a mapping for the key, the old value is replaced by the specified value.
If the return value of this operation will be ignored by the application, the user is strongly encouraged to use the IGNORE_RETURN_VALUES Flag when invoking this method in order to make it behave as efficiently as possible (i.e. avoiding needless remote or network calls).
key | key with which the specified value is to be associated |
val | value value to be associated with the specified key |
lifespan | the lifespan of this entry. A negative value is interpreted as unlimited lifespan |
lifespanUnit | TimeUnit for the lifespan param |
maxIdle | the maximum amount of time this entry is allowed to be idle before it is considered as expired |
maxIdleUnit | TimeUnit for the maxIdle param |
|
inline |
Copies all of the mappings from the specified map to this cache. The effect of this call is equivalent to that of calling put(k, v) on this cache once for each mapping from key k to value v in the specified map. The behavior of this operation is undefined if the specified map is modified while the operation is in progress.
map | to be stored in this cache |
lifespan | the lifespan of this entry. A negative value is interpreted as unlimited lifespan |
maxIdle | the maximum amount of time these object are allowed to be idle before they are considered as expired |
|
inline |
Copies all of the mappings from the specified map to this cache. The effect of this call is equivalent to that of calling put(k, v) on this cache once for each mapping from key k to value v in the specified map. The behavior of this operation is undefined if the specified map is modified while the operation is in progress.
map | to be stored in this cache |
lifespan | the lifespan of this entry. A negative value is interpreted as unlimited lifespan |
lifespanUnit | TimeUnit for the lifespan param |
|
inline |
Copies all of the mappings from the specified map to this cache. The effect of this call is equivalent to that of calling put(k, v) on this cache once for each mapping from key k to value v in the specified map. The behavior of this operation is undefined if the specified map is modified while the operation is in progress.
map | to be stored in this cache |
lifespan | the lifespan of this entry. A negative value is interpreted as unlimited lifespan |
lifespanUnit | TimeUnit for the lifespan param |
maxIdle | the maximum amount of time these object are allowed to be idle before they are considered as expired |
maxIdleUnit | TimeUnit for the maxIdle param |
|
inline |
Asynchronous version of putAll() See the synchronous doc for parameters not explained here
map | to be stored in this cache |
lifespan | the lifespan of these entries. A negative value is interpreted as unlimited lifespan |
maxIdle | the maximum amount of time these objects are allowed to be idle before they are considered as expired |
success | function to be executed on success |
fail | function to be executed if exceptions occur |
|
inline |
Asynchronous version of putAll() See the synchronous doc for parameters not explained here
map | to be stored in this cache |
lifespan | the lifespan of these entries. A negative value is interpreted as unlimited lifespan |
lifespanUnit | TimeUnit for the lifespan param |
success | function to be executed on success |
fail | function to be executed if exceptions occur |
|
inline |
Asynchronous version of putAll() See the synchronous doc for parameters not explained here
map | to be stored in this cache |
lifespan | the lifespan of these entries. A negative value is interpreted as unlimited lifespan |
lifespanUnit | TimeUnit for the lifespan param |
maxIdle | the maximum amount of time these are allowed to be idle before they are considered as expired |
maxIdleUnit | TimeUnit for the maxIdle param |
success | function to be executed on success |
fail | function to be executed if exceptions occur |
|
inline |
Asynchronous version of put()
key | key with which the specified value is to be associated |
val | value value to be associated with the specified key |
lifespan | the lifespan of this entry. A negative value is interpreted as unlimited lifespan |
maxIdle | the maximum amount of time this entry is allowed to be idle before it is considered as expired |
success | function to be executed on success |
fail | function to be executed if exceptions occur |
|
inline |
Asynchronous version of put()
key | key with which the specified value is to be associated |
val | value value to be associated with the specified key |
lifespan | the lifespan of this entry. A negative value is interpreted as unlimited lifespan |
lifespanUnit | TimeUnit for the lifespan param |
success | function to be executed on success |
fail | function to be executed if exceptions occur |
|
inline |
Asynchronous version of put()
key | key with which the specified value is to be associated |
val | value value to be associated with the specified key |
lifespan | the lifespan of this entry. A negative value is interpreted as unlimited lifespan |
lifespanUnit | TimeUnit for the lifespan param |
maxIdle | the maximum amount of time this entry is allowed to be idle before it is considered as expired |
maxIdleUnit | TimeUnit for the maxIdle param |
success | function to be executed on success |
fail | function to be executed if exceptions occur |
|
inline |
Associates the specified value with the specified key in this cache if the specified key is not already associated with some value. In such case key is associated with the given value.
key | key with which the specified value is to be associated |
val | value value to be associated with the specified key |
lifespan | the lifespan of this entry. A negative value is interpreted as unlimited lifespan |
maxIdle | the maximum amount of time this entry is allowed to be idle before it is considered as expired |
|
inline |
Associates the specified value with the specified key in this cache if the specified key is not already associated with some value. In such case key is associated with the given value.
key | key with which the specified value is to be associated |
val | value value to be associated with the specified key |
lifespan | the lifespan of this entry. A negative value is interpreted as unlimited lifespan |
lifespanUnit | TimeUnit for the lifespan param |
|
inline |
Associates the specified value with the specified key in this cache if the specified key is not already associated with some value. In such case key is associated with the given value.
key | key with which the specified value is to be associated |
val | value value to be associated with the specified key |
lifespan | the lifespan of this entry. A negative value is interpreted as unlimited lifespan |
lifespanUnit | TimeUnit for the lifespan param |
maxIdle | the maximum amount of time this entry is allowed to be idle before it is considered as expired |
maxIdleUnit | TimeUnit for the maxIdle param |
|
inline |
Asynchronous version of putIfAbsentAsync()
key | key with which the specified value is to be associated |
val | value value to be associated with the specified key |
lifespan | the lifespan of this entry. A negative value is interpreted as unlimited lifespan |
maxIdle | the maximum amount of time this entry is allowed to be idle before it is considered as expired |
success | function to be executed on success |
fail | function to be executed if exceptions occur |
|
inline |
Asynchronous version of putIfAbsentAsync()
key | key with which the specified value is to be associated |
val | value value to be associated with the specified key |
lifespan | the lifespan of this entry. A negative value is interpreted as unlimited lifespan |
lifespanUnit | TimeUnit for the lifespan param |
success | function to be executed on success |
fail | function to be executed if exceptions occur |
|
inline |
Asynchronous version of putIfAbsentAsync()
key | key with which the specified value is to be associated |
val | value value to be associated with the specified key |
lifespan | the lifespan of this entry. A negative value is interpreted as unlimited lifespan |
lifespanUnit | TimeUnit for the lifespan param |
maxIdle | the maximum amount of time this entry is allowed to be idle before it is considered as expired |
maxIdleUnit | TimeUnit for the maxIdle param |
success | function to be executed on success |
fail | function to be executed if exceptions occur |
|
inline |
Execute a query on server
qr | the QueryRequest oject |
|
inline |
Execute a query on server
qr | the query string |
size | the length of the query string |
|
inline |
Removes key/value pair from the cache given a key. Optionally return a value stored under the given key
key | the of the entry to be removed |
|
inline |
Asynchronous version of removeWithVersion() See the synchronous doc for parameters not explained here
key | the of the entry to be removed |
success | function to be executed on success |
fail | function to be executed if exceptions occur |
|
inline |
Stop and remove client listener
clientListener | the listener to be removed |
|
inline |
Start a client listener on the specified query and register it on the server
cql | object defining the query to be observed |
|
inline |
Removes the given entry only if its version matches the supplied version.
A typical use case looks like this:
std::pair<std::shared_ptr<std::string>, VersionedValue> rv = remoteCache.getWithVersioned(key); //some processing... remoteCache.removeWithVersion(key, rv.second().version);
Last call (removeWithVersion) will make sure that the entry will only be removed if it hasn't been changed in the meantime.
key | key |
version | version of entry to remove |
|
inline |
Asynchronous version of removeWithVersion()
key | key |
version | version of entry to remove |
success | function to be executed on success |
fail | function to be executed if exceptions occur |
|
inline |
Replaces the entry for a key with a given new value.
key | key with which the specified value is to be associated |
val | value to be associated with the specified key |
lifespan | lifespan of the entry. Negative values are interpreted as unlimited lifespan |
maxIdle | the maximum amount of time this entry is allowed to be idle before it is considered as expired |
|
inline |
Replaces the entry for a key with a given new value.
key | key with which the specified value is to be associated |
val | value to be associated with the specified key |
lifespan | lifespan of the entry. Negative values are interpreted as unlimited lifespan |
lifespanUnit | TimeUnit for the lifespan param |
|
inline |
Replaces the entry for a key with a given new value.
key | key with which the specified value is to be associated |
val | value to be associated with the specified key |
lifespan | lifespan of the entry. Negative values are interpreted as unlimited lifespan |
lifespanUnit | TimeUnit for the lifespan param |
maxIdle | the maximum amount of time this entry is allowed to be idle before it is considered as expired |
maxIdleUnit | TimeUnit for the maxIdle param |
|
inline |
Replaces the entry for a key with a new value only if currently mapped to a given old value.
key | key with which the specified value is to be associated |
oldVal | value expected to be associated with the specified key |
val | value to be associated with the specified key |
lifespan | lifespan of the entry. Negative values are interpreted as unlimited lifespan |
maxIdle | the maximum amount of time this entry is allowed to be idle before it is considered as expired |
|
inline |
Replaces the entry for a key with a new value only if currently mapped to a given old value.
key | key with which the specified value is to be associated |
oldVal | value expected to be associated with the specified key |
val | value to be associated with the specified key |
lifespan | lifespan of the entry. Negative values are interpreted as unlimited lifespan |
lifespanUnit | TimeUnit for the lifespan param |
|
inline |
Replaces the entry for a key with a new value only if currently mapped to a given old value.
key | key with which the specified value is to be associated |
oldVal | value expected to be associated with the specified key |
val | value to be associated with the specified key |
lifespan | lifespan of the entry. Negative values are interpreted as unlimited lifespan |
lifespanUnit | TimeUnit for the lifespan param |
maxIdle | the maximum amount of time this entry is allowed to be idle before it is considered as expired |
maxIdleUnit | TimeUnit for the maxIdle param |
|
inline |
Asynchronous version of replace()
key | key with which the specified value is to be associated |
val | value to be associated with the specified key |
lifespan | lifespan of the entry. Negative values are interpreted as unlimited lifespan |
maxIdle | the maximum amount of time this entry is allowed to be idle before it is considered as expired |
success | function to be executed on success |
fail | function to be executed if exceptions occur |
|
inline |
Asynchronous version of replace()
key | key with which the specified value is to be associated |
val | value to be associated with the specified key |
lifespan | lifespan of the entry. Negative values are interpreted as unlimited lifespan |
lifespanUnit | TimeUnit for the lifespan param |
success | function to be executed on success |
fail | function to be executed if exceptions occur |
|
inline |
Asynchronous version of replace()
key | key with which the specified value is to be associated |
val | value to be associated with the specified key |
lifespan | lifespan of the entry. Negative values are interpreted as unlimited lifespan |
lifespanUnit | TimeUnit for the lifespan param |
maxIdle | the maximum amount of time this entry is allowed to be idle before it is considered as expired |
maxIdleUnit | TimeUnit for the maxIdle param |
success | function to be executed on success |
fail | function to be executed if exceptions occur |
|
inline |
Asynchronous version of replace() See the synchronous doc for parameters not explained here
key | key with which the specified value is to be associated |
oldVal | value expected to be associated with the specified key |
val | value to be associated with the specified key |
lifespan | lifespan of the entry. Negative values are interpreted as unlimited lifespan |
maxIdle | the maximum amount of time this entry is allowed to be idle before it is considered as expired |
success | function to be executed on success |
fail | function to be executed if exceptions occur |
|
inline |
Asynchronous version of replace() See the synchronous doc for parameters not explained here
key | key with which the specified value is to be associated |
oldVal | value expected to be associated with the specified key |
val | value to be associated with the specified key |
lifespan | lifespan of the entry. Negative values are interpreted as unlimited lifespan |
lifespanUnit | TimeUnit for the lifespan param |
success | function to be executed on success |
fail | function to be executed if exceptions occur |
|
inline |
Replaces the given value only if its version matches the supplied version.
key | the key |
val | the new value for the given key |
version | numeric version that should match the one in the server for the operation to succeed |
lifespan | the new lifespan for this key/value entry pair |
maxIdle | the maximum amount of time this entry is allowed to be idle before it is considered as expired |
|
inline |
Asynchronous version of replaceWithVersion()
key | the key |
val | the new value for the given key |
version | numeric version that should match the one in the server for the operation to succeed |
lifespan | the new lifespan for this key/value entry pair |
maxIdle | the maximum amount of time this entry is allowed to be idle before it is considered as expired |
success | function to be executed on success |
fail | function to be executed if exceptions occur |
|
inline |
Returns an approximate number of key/value pairs in this cache.
|
inline |
Returns statistics for this cache.
|
inline |
Unsupported operation in this release of Hot Rod client. UnsupportedOperationException is thrown if his method is invoked.
|
inline |
Applies one or more Flag enums to the scope of a single invocation.
flags | the flags to apply to an invocation |
|
friend |