public abstract class RemoteCacheSupport<K,V> extends Object implements RemoteCache<K,V>
Modifier and Type | Field and Description |
---|---|
protected long |
defaultLifespan |
protected long |
defaultMaxIdleTime |
Modifier | Constructor and Description |
---|---|
protected |
RemoteCacheSupport() |
protected |
RemoteCacheSupport(long defaultLifespan,
long defaultMaxIdleTime) |
Modifier and Type | Method and Description |
---|---|
boolean |
containsValue(Object value) |
Set<Map.Entry<K,V>> |
entrySet() |
V |
put(K key,
V value) |
V |
put(K key,
V value,
long lifespan,
TimeUnit unit) |
void |
putAll(Map<? extends K,? extends V> map)
Synthetic operation.
|
void |
putAll(Map<? extends K,? extends V> map,
long lifespan,
TimeUnit unit)
Synthetic operation.
|
org.infinispan.commons.util.concurrent.NotifyingFuture<Void> |
putAllAsync(Map<? extends K,? extends V> data)
Synthetic operation.
|
org.infinispan.commons.util.concurrent.NotifyingFuture<Void> |
putAllAsync(Map<? extends K,? extends V> data,
long lifespan,
TimeUnit unit)
Synthetic operation.
|
org.infinispan.commons.util.concurrent.NotifyingFuture<V> |
putAsync(K key,
V value) |
org.infinispan.commons.util.concurrent.NotifyingFuture<V> |
putAsync(K key,
V value,
long lifespan,
TimeUnit unit) |
V |
putIfAbsent(K key,
V value) |
V |
putIfAbsent(K key,
V value,
long lifespan,
TimeUnit unit) |
org.infinispan.commons.util.concurrent.NotifyingFuture<V> |
putIfAbsentAsync(K key,
V value) |
org.infinispan.commons.util.concurrent.NotifyingFuture<V> |
putIfAbsentAsync(K key,
V value,
long lifespan,
TimeUnit lifespanUnit) |
boolean |
remove(Object key,
Object value) |
org.infinispan.commons.util.concurrent.NotifyingFuture<Boolean> |
removeAsync(Object key,
Object value) |
V |
replace(K key,
V value) |
V |
replace(K key,
V value,
long lifespan,
TimeUnit unit) |
boolean |
replace(K key,
V oldValue,
V newValue) |
boolean |
replace(K key,
V oldValue,
V value,
long lifespan,
TimeUnit unit) |
boolean |
replace(K key,
V oldValue,
V value,
long lifespan,
TimeUnit lifespanUnit,
long maxIdleTime,
TimeUnit maxIdleTimeUnit) |
org.infinispan.commons.util.concurrent.NotifyingFuture<V> |
replaceAsync(K key,
V value) |
org.infinispan.commons.util.concurrent.NotifyingFuture<V> |
replaceAsync(K key,
V value,
long lifespan,
TimeUnit unit) |
org.infinispan.commons.util.concurrent.NotifyingFuture<Boolean> |
replaceAsync(K key,
V oldValue,
V newValue) |
org.infinispan.commons.util.concurrent.NotifyingFuture<Boolean> |
replaceAsync(K key,
V oldValue,
V newValue,
long lifespan,
TimeUnit unit) |
org.infinispan.commons.util.concurrent.NotifyingFuture<Boolean> |
replaceAsync(K key,
V oldValue,
V newValue,
long lifespan,
TimeUnit lifespanUnit,
long maxIdle,
TimeUnit maxIdleUnit) |
boolean |
replaceWithVersion(K key,
V newValue,
long version)
Replaces the given value only if its version matches the supplied version.
|
boolean |
replaceWithVersion(K key,
V newValue,
long version,
int lifespanSeconds)
A overloaded form of
RemoteCache.replaceWithVersion(Object, Object, long)
which takes in lifespan parameters. |
org.infinispan.commons.util.concurrent.NotifyingFuture<Boolean> |
replaceWithVersionAsync(K key,
V newValue,
long version) |
org.infinispan.commons.util.concurrent.NotifyingFuture<Boolean> |
replaceWithVersionAsync(K key,
V newValue,
long version,
int lifespanSeconds) |
protected abstract void |
set(K key,
V value)
This is intentionally a non-public method meant as an integration point for bytecode manipulation.
|
Collection<V> |
values() |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getBulk, getBulk, getProtocolVersion, getRemoteCacheManager, getVersioned, getWithMetadata, isEmpty, keySet, putAll, putAllAsync, removeWithVersion, removeWithVersionAsync, replaceWithVersion, replaceWithVersionAsync, size, stats, withFlags
getName, getVersion, put, putIfAbsent, remove, replace
protected long defaultLifespan
protected long defaultMaxIdleTime
protected RemoteCacheSupport()
protected RemoteCacheSupport(long defaultLifespan, long defaultMaxIdleTime)
public void putAll(Map<? extends K,? extends V> map, long lifespan, TimeUnit unit)
RemoteCache
public org.infinispan.commons.util.concurrent.NotifyingFuture<Void> putAllAsync(Map<? extends K,? extends V> data)
RemoteCache
putAllAsync
in interface RemoteCache<K,V>
putAllAsync
in interface org.infinispan.commons.api.AsyncCache<K,V>
RemoteCache.putAll(java.util.Map, long, java.util.concurrent.TimeUnit)
public org.infinispan.commons.util.concurrent.NotifyingFuture<Void> putAllAsync(Map<? extends K,? extends V> data, long lifespan, TimeUnit unit)
RemoteCache
putAllAsync
in interface RemoteCache<K,V>
putAllAsync
in interface org.infinispan.commons.api.AsyncCache<K,V>
RemoteCache.putAll(java.util.Map, long, java.util.concurrent.TimeUnit)
public void putAll(Map<? extends K,? extends V> map)
RemoteCache
putAll
in interface Map<K,V>
putAll
in interface RemoteCache<K,V>
RemoteCache.putAll(java.util.Map, long, java.util.concurrent.TimeUnit)
public V putIfAbsent(K key, V value)
putIfAbsent
in interface ConcurrentMap<K,V>
public boolean replace(K key, V oldValue, V newValue)
replace
in interface ConcurrentMap<K,V>
protected abstract void set(K key, V value)
public final org.infinispan.commons.util.concurrent.NotifyingFuture<V> putAsync(K key, V value)
public org.infinispan.commons.util.concurrent.NotifyingFuture<V> putAsync(K key, V value, long lifespan, TimeUnit unit)
public org.infinispan.commons.util.concurrent.NotifyingFuture<Boolean> replaceWithVersionAsync(K key, V newValue, long version)
replaceWithVersionAsync
in interface RemoteCache<K,V>
RemoteCache.replaceWithVersion(Object, Object, long)
public org.infinispan.commons.util.concurrent.NotifyingFuture<Boolean> replaceWithVersionAsync(K key, V newValue, long version, int lifespanSeconds)
replaceWithVersionAsync
in interface RemoteCache<K,V>
RemoteCache.replaceWithVersion(Object, Object, long)
public boolean replaceWithVersion(K key, V newValue, long version)
RemoteCache
RemoteCache.removeWithVersion(Object, long)
for a sample usage of the
version-based methods.replaceWithVersion
in interface RemoteCache<K,V>
version
- numeric version that should match the one in the server
for the operation to succeedRemoteCache.getVersioned(Object)
,
VersionedValue
public boolean replaceWithVersion(K key, V newValue, long version, int lifespanSeconds)
RemoteCache
RemoteCache.replaceWithVersion(Object, Object, long)
which takes in lifespan parameters.replaceWithVersion
in interface RemoteCache<K,V>
key
- key to usenewValue
- new value to be associated with the keyversion
- numeric version that should match the one in the server
for the operation to succeedlifespanSeconds
- lifespan of the entrypublic org.infinispan.commons.util.concurrent.NotifyingFuture<V> replaceAsync(K key, V value)
public org.infinispan.commons.util.concurrent.NotifyingFuture<V> putIfAbsentAsync(K key, V value)
public org.infinispan.commons.util.concurrent.NotifyingFuture<V> putIfAbsentAsync(K key, V value, long lifespan, TimeUnit lifespanUnit)
public boolean containsValue(Object value)
containsValue
in interface Map<K,V>
containsValue
in interface RemoteCache<K,V>
public Collection<V> values()
public boolean remove(Object key, Object value)
remove
in interface ConcurrentMap<K,V>
public org.infinispan.commons.util.concurrent.NotifyingFuture<Boolean> removeAsync(Object key, Object value)
public org.infinispan.commons.util.concurrent.NotifyingFuture<V> replaceAsync(K key, V value, long lifespan, TimeUnit unit)
public org.infinispan.commons.util.concurrent.NotifyingFuture<Boolean> replaceAsync(K key, V oldValue, V newValue)
public org.infinispan.commons.util.concurrent.NotifyingFuture<Boolean> replaceAsync(K key, V oldValue, V newValue, long lifespan, TimeUnit unit)
public org.infinispan.commons.util.concurrent.NotifyingFuture<Boolean> replaceAsync(K key, V oldValue, V newValue, long lifespan, TimeUnit lifespanUnit, long maxIdle, TimeUnit maxIdleUnit)
Copyright © 2013 JBoss, a division of Red Hat. All Rights Reserved.