org.apache.ignite.internal.processors.cache.distributed.dht.atomic

## Class GridDhtAtomicCache<K,V>

- java.lang.Object
- - org.apache.ignite.internal.processors.cache.GridCacheAdapter<K,V>
  - - org.apache.ignite.internal.processors.cache.distributed.GridDistributedCacheAdapter<K,V>
    - - org.apache.ignite.internal.processors.cache.distributed.dht.GridDhtCacheAdapter<K,V>
      - - org.apache.ignite.internal.processors.cache.distributed.dht.atomic.GridDhtAtomicCache<K,V>

All Implemented Interfaces:
  Externalizable, Serializable, Iterable<javax.cache.Cache.Entry<K,V>>, CacheProjection<K,V>, GridCache<K,V>, GridCacheProjectionEx<K,V>

    @GridToStringExclude
    public class GridDhtAtomicCache<K,V>
    extends GridDhtCacheAdapter<K,V>

Non-transactional partitioned cache.

See Also:
  Serialized Form

### Nested Class Summary

### Nested classes/interfaces inherited from class org.apache.ignite.internal.processors.cache.GridCacheAdapter

`GridCacheAdapter.AsyncOp<T>, GridCacheAdapter.CacheExpiryPolicy, GridCacheAdapter.FutureHolder, GridCacheAdapter.UpdateGetTimeStatClosure<T>, GridCacheAdapter.UpdatePutAndGetTimeStatClosure<T>, GridCacheAdapter.UpdatePutTimeStatClosure<T>, GridCacheAdapter.UpdateRemoveTimeStatClosure<T>, GridCacheAdapter.UpdateTimeStatClosure<T>`

### Field Summary

### Fields inherited from class org.apache.ignite.internal.processors.cache.distributed.dht.GridDhtCacheAdapter

`preldr`

### Fields inherited from class org.apache.ignite.internal.processors.cache.GridCacheAdapter

`cacheCfg, CLEAR_ALL_SPLIT_THRESHOLD, ctx, gridCfg, keyCheck, lastFut, locNodeId, log, map, metrics, mxBean, RET2NULL`

### Constructor Summary

Constructors
Constructor and Description
`GridDhtAtomicCache()` Empty constructor required by `Externalizable`.
`GridDhtAtomicCache(GridCacheContext<K,V> ctx)`
`GridDhtAtomicCache(GridCacheContext<K,V> ctx, GridCacheConcurrentMap map)`

### Method Summary

Methods
`protected <T> IgniteInternalFuture<T>` `asyncOp(CO<IgniteInternalFuture<T>> op)`
`javax.cache.Cache.Entry<K,V>` `entry(K key)` Gets entry from cache with the specified key.
`IgniteInternalFuture<Map<K,V>>` `getAllAsync(Collection<? extends K> keys, boolean forcePrimary, boolean skipTx, GridCacheEntryEx entry, UUID subjId, String taskName, boolean deserializePortable, boolean skipVals)` This method is used internally.
`protected void` `init()` Post constructor initialization for subclasses.
`<T> javax.cache.processor.EntryProcessorResult<T>` `invoke(K key, javax.cache.processor.EntryProcessor<K,V,T> entryProcessor, Object... args)`
`<T> Map<K,javax.cache.processor.EntryProcessorResult<T>>` `invokeAll(Map<? extends K,? extends javax.cache.processor.EntryProcessor<K,V,T>> map, Object... args)`
`<T> Map<K,javax.cache.processor.EntryProcessorResult<T>>` `invokeAll(Set<? extends K> keys, javax.cache.processor.EntryProcessor<K,V,T> entryProcessor, Object... args)`
`<T> IgniteInternalFuture<Map<K,javax.cache.processor.EntryProcessorResult<T>>>` `invokeAllAsync(Map<? extends K,? extends javax.cache.processor.EntryProcessor<K,V,T>> map, Object... args)`
`<T> IgniteInternalFuture<Map<K,javax.cache.processor.EntryProcessorResult<T>>>` `invokeAllAsync(Set<? extends K> keys, javax.cache.processor.EntryProcessor<K,V,T> entryProcessor, Object... args)`
`<T> IgniteInternalFuture<javax.cache.processor.EntryProcessorResult<T>>` `invokeAsync(K key, javax.cache.processor.EntryProcessor<K,V,T> entryProcessor, Object... args)`
`boolean` `isDhtAtomic()`
`void` `localRemoveAll()`
`IgniteInternalFuture<?>` `localRemoveAll(CacheEntryPredicate filter)`
`protected IgniteInternalFuture<Boolean>` `lockAllAsync(Collection<KeyCacheObject> keys, long timeout, IgniteTxLocalEx tx, boolean isInvalidate, boolean isRead, boolean retval, TransactionIsolation isolation, long accessTtl, CacheEntryPredicate[] filter)`
`GridNearCacheAdapter<K,V>` `near()`
`void` `near(GridNearAtomicCache<K,V> near)`
`V` `peek(K key, Collection<GridCachePeekMode> modes)` Peeks at cached value using optional set of peek modes.
`V` `put(K key, V val, GridCacheEntryEx cached, long ttl, CacheEntryPredicate[] filter)` Internal method that is called from `CacheEntryImpl`.
`void` `putAll(Map<? extends K,? extends V> m, CacheEntryPredicate[] filter)` Stores given key-value pairs in cache.
`IgniteInternalFuture<?>` `putAllAsync(Map<? extends K,? extends V> m, CacheEntryPredicate[] filter)` Asynchronously stores given key-value pairs in cache.
`void` `putAllConflict(Map<KeyCacheObject,GridCacheDrInfo> conflictMap)` Store DR data.
`IgniteInternalFuture<?>` `putAllConflictAsync(Map<KeyCacheObject,GridCacheDrInfo> conflictMap)` Store DR data asynchronously.
`IgniteInternalFuture<V>` `putAsync(K key, V val, GridCacheEntryEx entry, long ttl, CacheEntryPredicate... filter)` Internal method that is called from `CacheEntryImpl`.
`V` `putIfAbsent(K key, V val)` Stores given key-value pair in cache only if cache had no previous mapping for it.
`IgniteInternalFuture<V>` `putIfAbsentAsync(K key, V val)` Asynchronously stores given key-value pair in cache only if cache had no previous mapping for it.
`boolean` `putx(K key, V val, CacheEntryPredicate[] filter)` Stores given key-value pair in cache.
`boolean` `putx(K key, V val, GridCacheEntryEx cached, long ttl, CacheEntryPredicate... filter)` Internal method that is called from `CacheEntryImpl`.
`IgniteInternalFuture<Boolean>` `putxAsync(K key, V val, GridCacheEntryEx entry, long ttl, CacheEntryPredicate... filter)` Internal method that is called from `CacheEntryImpl`.
`boolean` `putxIfAbsent(K key, V val)` Stores given key-value pair in cache only if cache had no previous mapping for it.
`IgniteInternalFuture<Boolean>` `putxIfAbsentAsync(K key, V val)` Asynchronously stores given key-value pair in cache only if cache had no previous mapping for it.
`V` `remove(K key, GridCacheEntryEx entry, CacheEntryPredicate... filter)` Internal method that is called from `CacheEntryImpl`.
`boolean` `remove(K key, V val)` Removes given key mapping from cache if one exists and value is equal to the passed in value.
`void` `removeAll(Collection<? extends K> keys, CacheEntryPredicate... filter)` Removes given key mappings from cache for entries for which the optionally passed in filters do pass.
`IgniteInternalFuture<?>` `removeAllAsync(Collection<? extends K> keys, CacheEntryPredicate[] filter)` Asynchronously removes given key mappings from cache for entries for which the optionally passed in filters do pass.
`void` `removeAllConflict(Map<KeyCacheObject,GridCacheVersion> conflictMap)` Removes DR data.
`IgniteInternalFuture<?>` `removeAllConflictAsync(Map<KeyCacheObject,GridCacheVersion> conflictMap)` Removes DR data asynchronously.
`IgniteInternalFuture<V>` `removeAsync(K key, GridCacheEntryEx entry, CacheEntryPredicate... filter)` Internal method that is called from `CacheEntryImpl`.
`IgniteInternalFuture<Boolean>` `removeAsync(K key, V val)` Asynchronously removes given key mapping from cache if one exists and value is equal to the passed in value.
`boolean` `removex(K key, GridCacheEntryEx entry, CacheEntryPredicate... filter)` Internal method that is called from `CacheEntryImpl`.
`GridCacheReturn` `removex(K key, V val)` Removes given key mapping from cache if one exists and value is equal to the passed in value.
`IgniteInternalFuture<Boolean>` `removexAsync(K key, GridCacheEntryEx entry, CacheEntryPredicate... filter)` Internal method that is called from `CacheEntryImpl`.
`IgniteInternalFuture<GridCacheReturn>` `removexAsync(K key, V val)` Asynchronously removes given key mapping from cache if one exists and value is equal to the passed in value.
`V` `replace(K key, V val)` Stores given key-value pair in cache only if there is a previous mapping for it.
`boolean` `replace(K key, V oldVal, V newVal)` Stores given key-value pair in cache only if only if the previous value is equal to the `'oldVal'` passed in.
`IgniteInternalFuture<V>` `replaceAsync(K key, V val)` Asynchronously stores given key-value pair in cache only if there is a previous mapping for it.
`IgniteInternalFuture<Boolean>` `replaceAsync(K key, V oldVal, V newVal)` Asynchronously stores given key-value pair in cache only if only if the previous value is equal to the `'oldVal'` passed in.
`boolean` `replacex(K key, V val)` Stores given key-value pair in cache only if only if there is a previous mapping for it.
`GridCacheReturn` `replacex(K key, V oldVal, V newVal)` Stores given key-value pair in cache only if only if the previous value is equal to the `'oldVal'` passed in.
`IgniteInternalFuture<Boolean>` `replacexAsync(K key, V val)` Asynchronously stores given key-value pair in cache only if only if there is a previous mapping for it.
`IgniteInternalFuture<GridCacheReturn>` `replacexAsync(K key, V oldVal, V newVal)` Asynchronously stores given key-value pair in cache only if only if the previous value is equal to the `'oldVal'` passed in.
`void` `start()` Starts this cache.
`void` `stop()` Stops this cache.
`String` `toString()`
`V` `tryPutIfAbsent(K key, V val)` Tries to put value in cache.
`void` `updateAllAsyncInternal(UUID nodeId, GridNearAtomicUpdateRequest req, CI2<GridNearAtomicUpdateRequest,GridNearAtomicUpdateResponse> completionCb)` Executes local update.
`void` `updateAllAsyncInternal0(UUID nodeId, GridNearAtomicUpdateRequest req, CI2<GridNearAtomicUpdateRequest,GridNearAtomicUpdateResponse> completionCb)` Executes local update after preloader fetched values.

### Methods inherited from class org.apache.ignite.internal.processors.cache.distributed.dht.GridDhtCacheAdapter

`beginMultiUpdate, dhtPreloader, endMultiUpdate, entryEx, entryEx, entryExx, entryExx, entryExx, entrySet, getDhtAsync, localEntriesIterator, localLoad, localLoadCache, multiUpdateFinishFuture, multiUpdateTopologyFuture, onDeferredDelete, onKernalStart, onKernalStop, peekExx, preloader, primarySize, printMemoryStats, processNearGetRequest, reload, sendTtlUpdateRequest, splitClearLocally, topology, unlockAll`

### Methods inherited from class org.apache.ignite.internal.processors.cache.distributed.GridDistributedCacheAdapter

`lockAllAsync, removeAll, removeAllAsync, removeVersionedEntry, txLockAsync`

### Methods inherited from class org.apache.ignite.internal.processors.cache.GridCacheAdapter

`affinity, affinityNode, allEntries, asyncOp, asyncOpAcquire, asyncOpRelease, awaitLastFut, cache, checkJta, clear, clear, clear, clearAll, clearAsync, clearAsync, clearAsync, clearLocally, clearLocally, clearLocally, clearLocally0, clearLocally0, clearLocallyAll, commitTxAsync, configuration, containsKey, containsKeyAsync, containsKeys, containsKeysAsync, containsValue, context, entries, entryEx, entryEx, entryExSafe, entrySet, entrySet, entrySetx, evict, evict, evictAll, evictAll, evictAll, expiry, expiryPolicy, flags, flagsOff, flagsOn, forceRepartition, forSubjectId, get, get, get, getAll, getAll, getAllAsync, getAllAsync, getAllAsync, getAllAsync0, getAllOutTx, getAllOutTxAsync, getAsync, getAsync, getForcePrimary, getForcePrimaryAsync, globalPrimarySize, globalSize, gridProjection, igfsDataSpaceMax, igfsDataSpaceUsed, igniteIterator, isColocated, isDht, isEmpty, isIgfsDataCache, isLocal, isLocked, isLockedByThread, isMongoDataCache, isMongoMetaCache, isNear, iterator, iterator, keepPortable, keepPortable0, keySet, keySet, loadAll, localEntries, localLoadCacheAsync, localPeek, localSize, lock, lockAll, lockAsync, log, map, metrics, metrics0, mxBean, name, nearSize, offHeapAllocatedSize, offHeapEntriesCount, offHeapIterator, onIgfsDataSizeChanged, onUndeploy, overflowSize, peek, peek, peek0, peek0, peek0, peekAll0, peekEx, peekEx, predicate, primaryEntrySet, primaryEntrySet, primaryEntrySetx, primaryKeySet, primaryKeySet, primaryValues, primaryValues, projection, projection, promote, promote, promoteAll, put, putAsync, putxAsync, queries, randomEntry, readExternal, readResolve, readThroughAllAsync, reloadAllAsync0, reloadAsync, remove, removeAsync, removeEntry, removeIfObsolete, removex, removexAsync, saveFuture, size, size, sizeAsync, startInfo, stopInfo, swapIterator, swapKeys, swapSize, toMap, tx, txStart, txStart, txStart, txStartEx, txSynchronizations, txSynchronize, txUnsynchronize, unlock, validateCacheKey, validateCacheKeys, values, values, withExpiryPolicy, writeExternal`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

### Constructor Detail

#### GridDhtAtomicCache

    public GridDhtAtomicCache()

Empty constructor required by `Externalizable`.

#### GridDhtAtomicCache

    public GridDhtAtomicCache(GridCacheContext<K,V> ctx)

Parameters:
  `ctx` - Cache context.

#### GridDhtAtomicCache

    public GridDhtAtomicCache(GridCacheContext<K,V> ctx,
                      GridCacheConcurrentMap map)

Parameters:
  `ctx` - Cache context.
  `map` - Cache concurrent map.

### Method Detail

#### isDhtAtomic

    public boolean isDhtAtomic()

Overrides:
  `isDhtAtomic` in class `GridCacheAdapter<K,V>`
Returns:
  `True` if cache is DHT Atomic.

#### init

    protected void init()

Post constructor initialization for subclasses.

Overrides:
  `init` in class `GridDhtCacheAdapter<K,V>`

#### start

    public void start()
               throws IgniteCheckedException

Starts this cache. Child classes should override this method to provide custom start-up behavior.

Overrides:
  `start` in class `GridDhtCacheAdapter<K,V>`
Throws:
  `IgniteCheckedException` - If start failed.

#### stop

    public void stop()

Stops this cache. Child classes should override this method to provide custom stop behavior.

Overrides:
  `stop` in class `GridDhtCacheAdapter<K,V>`

#### near

    public void near(GridNearAtomicCache<K,V> near)

Parameters:
  `near` - Near cache.

#### near

    public GridNearCacheAdapter<K,V> near()

Specified by:
  `near` in class `GridDhtCacheAdapter<K,V>`
Returns:
  Near cache.

#### entry

    public javax.cache.Cache.Entry<K,V> entry(K key)
                                       throws GridDhtInvalidPartitionException

Gets entry from cache with the specified key. The returned entry can be used even after entry key has been removed from cache. In that case, every operation on returned entry will result in creation of a new entry.

Note that this method can return `null` if projection is configured as pre-filtered and entry key and value don't pass key-value filter of the projection.

Specified by:
  `entry` in interface `CacheProjection<K,V>`
Overrides:
  `entry` in class `GridDhtCacheAdapter<K,V>`
Parameters:
  `key` - Entry key.
Returns:
  Cache entry or `null` if projection pre-filtering was not passed.
Throws:
  `GridDhtInvalidPartitionException` - If partition for the key is no longer valid.

#### peek

    public V peek(K key,
         @Nullable
         Collection<GridCachePeekMode> modes)
           throws IgniteCheckedException

Peeks at cached value using optional set of peek modes. This method will sequentially iterate over given peek modes in the order passed in, and try to peek at value using each peek mode. Once a `non-null` value is found, it will be immediately returned.

Note that if modes are not provided this method works exactly the same way as `CacheProjection.peek(Object)`, implicitly using `GridCachePeekMode.SMART` mode.

## Transactions

This method does not participate in any transactions, however, it may peek at transactional value depending on the peek modes used.

Specified by:
  `peek` in interface `CacheProjection<K,V>`
Overrides:
  `peek` in class `GridCacheAdapter<K,V>`
Parameters:
  `key` - Entry key.
  `modes` - Optional set of peek modes.
Returns:
  Peeked value.
Throws:
  `IgniteCheckedException` - If peek operation failed.

#### getAllAsync

    public IgniteInternalFuture<Map<K,V>> getAllAsync(@Nullable
                                             Collection<? extends K> keys,
                                             boolean forcePrimary,
                                             boolean skipTx,
                                             @Nullable
                                             GridCacheEntryEx entry,
                                             @Nullable
                                             UUID subjId,
                                             String taskName,
                                             boolean deserializePortable,
                                             boolean skipVals)

This method is used internally. Use `GridDhtCacheAdapter.getDhtAsync(UUID, long, LinkedHashMap, boolean, boolean, AffinityTopologyVersion, UUID, int, IgniteCacheExpiryPolicy, boolean)` method instead to retrieve DHT value.

Overrides:
  `getAllAsync` in class `GridDhtCacheAdapter<K,V>`
Parameters:
  `keys` - Keys.
  `forcePrimary` - Force primary.
  `skipTx` - Skip tx.
  `entry` - Entry.
  `subjId` - Subj Id.
  `taskName` - Task name.
  `deserializePortable` - Deserialize portable.
  `skipVals` - Skip values.
Returns:
  Future for the get operation.
See Also:
  `GridCacheAdapter.getAllAsync(Collection)`

#### put

    public V put(K key,
        V val,
        @Nullable
        GridCacheEntryEx cached,
        long ttl,
        @Nullable
        CacheEntryPredicate[] filter)
          throws IgniteCheckedException

Internal method that is called from `CacheEntryImpl`.

Specified by:
  `put` in interface `GridCacheProjectionEx<K,V>`
Overrides:
  `put` in class `GridCacheAdapter<K,V>`
Parameters:
  `key` - Key.
  `val` - Value.
  `cached` - Cached entry. If not provided, equivalent to {CacheProjection#put}.
  `ttl` - Optional time-to-live. If negative, leaves ttl value unchanged.
  `filter` - Optional filter.
Returns:
  Previous value.
Throws:
  `IgniteCheckedException` - If failed.

#### putx

    public boolean putx(K key,
               V val,
               @Nullable
               GridCacheEntryEx cached,
               long ttl,
               @Nullable
               CacheEntryPredicate... filter)
                 throws IgniteCheckedException

Internal method that is called from `CacheEntryImpl`.

Specified by:
  `putx` in interface `GridCacheProjectionEx<K,V>`
Overrides:
  `putx` in class `GridCacheAdapter<K,V>`
Parameters:
  `key` - Key.
  `val` - Value.
  `cached` - Cached entry. If not provided, equivalent to {CacheProjection#put}.
  `ttl` - Optional time-to-live. If negative, leaves ttl value unchanged.
  `filter` - Optional filter.
Returns:
  Previous value.
Throws:
  `IgniteCheckedException` - If failed.

#### putx

    public boolean putx(K key,
               V val,
               CacheEntryPredicate[] filter)
                 throws IgniteCheckedException

Stores given key-value pair in cache. If filters are provided, then entries will be stored in cache only if they pass the filter. Note that filter check is atomic, so value stored in cache is guaranteed to be consistent with the filters.

This method will return `true` if value is stored in cache and `false` otherwise. Unlike `#put(Object, Object, org.apache.ignite.lang.IgnitePredicate[])` method, it does not return previous value and, therefore, does not have any overhead associated with returning a value. It should be used whenever return value is not required.

If write-through is enabled, the stored value will be persisted to `CacheStore` via `CacheStore#put(Transaction, Object, Object)` method.

## Transactions

This method is transactional and will enlist the entry into ongoing transaction if there is one.

## Cache Flags

This method is not available if any of the following flags are set on projection: `CacheFlag.LOCAL`, `CacheFlag.READ`.

Specified by:
  `putx` in interface `CacheProjection<K,V>`
Overrides:
  `putx` in class `GridCacheAdapter<K,V>`
Parameters:
  `key` - Key to store in cache.
  `val` - Value to be associated with the given key.
  `filter` - Optional filter to check prior to putting value in cache. Note that filter check is atomic with put operation.
Returns:
  `True` if optional filter passed and value was stored in cache, `false` otherwise. Note that this method will return `true` if filter is not specified.
Throws:
  `IgniteCheckedException` - If put operation failed.

#### putAsync

    public IgniteInternalFuture<V> putAsync(K key,
                                   V val,
                                   @Nullable
                                   GridCacheEntryEx entry,
                                   long ttl,
                                   @Nullable
                                   CacheEntryPredicate... filter)

Internal method that is called from `CacheEntryImpl`.

Specified by:
  `putAsync` in interface `GridCacheProjectionEx<K,V>`
Overrides:
  `putAsync` in class `GridCacheAdapter<K,V>`
Parameters:
  `key` - Key.
  `val` - Value.
  `entry` - Optional cached entry.
  `ttl` - Optional time-to-live value. If negative, leaves ttl value unchanged.
  `filter` - Optional filter.
Returns:
  Put operation future.

#### putxAsync

    public IgniteInternalFuture<Boolean> putxAsync(K key,
                                          V val,
                                          @Nullable
                                          GridCacheEntryEx entry,
                                          long ttl,
                                          @Nullable
                                          CacheEntryPredicate... filter)

Internal method that is called from `CacheEntryImpl`.

Specified by:
  `putxAsync` in interface `GridCacheProjectionEx<K,V>`
Overrides:
  `putxAsync` in class `GridCacheAdapter<K,V>`
Parameters:
  `key` - Key.
  `val` - Value.
  `entry` - Cached entry. If not provided, equivalent to {CacheProjection#put}.
  `ttl` - Optional time-to-live. If negative, leave ttl value unchanged.
  `filter` - Optional filter.
Returns:
  Putx operation future.

#### tryPutIfAbsent

    public V tryPutIfAbsent(K key,
                   V val)
                     throws IgniteCheckedException

Tries to put value in cache. Will fail with `GridCacheTryPutFailedException` if topology exchange is in progress.

Overrides:
  `tryPutIfAbsent` in class `GridCacheAdapter<K,V>`
Parameters:
  `key` - Key.
  `val` - value.
Returns:
  Old value.
Throws:
  `IgniteCheckedException` - In case of error.

#### putIfAbsent

    public V putIfAbsent(K key,
                V val)
                  throws IgniteCheckedException

Stores given key-value pair in cache only if cache had no previous mapping for it. If cache previously contained value for the given key, then this value is returned. In case of `CacheMode.PARTITIONED` or `CacheMode.REPLICATED` caches, the value will be loaded from the primary node, which in its turn may load the value from the swap storage, and consecutively, if it's not in swap, from the underlying persistent storage. If value has to be loaded from persistent storage, `CacheStore#load(Transaction, Object)` method will be used.

If the returned value is not needed, method `CacheProjection.putxIfAbsent(Object, Object)` should always be used instead of this one to avoid the overhead associated with returning of the previous value.

If write-through is enabled, the stored value will be persisted to `CacheStore` via `CacheStore#put(Transaction, Object, Object)` method.

## Transactions

This method is transactional and will enlist the entry into ongoing transaction if there is one.

## Cache Flags

This method is not available if any of the following flags are set on projection: `CacheFlag.LOCAL`, `CacheFlag.READ`.

Specified by:
  `putIfAbsent` in interface `CacheProjection<K,V>`
Overrides:
  `putIfAbsent` in class `GridCacheAdapter<K,V>`
Parameters:
  `key` - Key to store in cache.
  `val` - Value to be associated with the given key.
Returns:
  Previously contained value regardless of whether put happened or not.
Throws:
  `IgniteCheckedException` - If put operation failed.

#### putIfAbsentAsync

    public IgniteInternalFuture<V> putIfAbsentAsync(K key,
                                           V val)

Asynchronously stores given key-value pair in cache only if cache had no previous mapping for it. If cache previously contained value for the given key, then this value is returned. In case of `CacheMode.PARTITIONED` or `CacheMode.REPLICATED` caches, the value will be loaded from the primary node, which in its turn may load the value from the swap storage, and consecutively, if it's not in swap, from the underlying persistent storage. If value has to be loaded from persistent storage, `CacheStore#load(Transaction, Object)` method will be used.

If the returned value is not needed, method `CacheProjection.putxIfAbsentAsync(Object, Object)` should always be used instead of this one to avoid the overhead associated with returning of the previous value.

If write-through is enabled, the stored value will be persisted to `CacheStore` via `CacheStore#put(Transaction, Object, Object)` method.

## Transactions

This method is transactional and will enlist the entry into ongoing transaction if there is one.

## Cache Flags

This method is not available if any of the following flags are set on projection: `CacheFlag.LOCAL`, `CacheFlag.READ`.

Specified by:
  `putIfAbsentAsync` in interface `CacheProjection<K,V>`
Overrides:
  `putIfAbsentAsync` in class `GridCacheAdapter<K,V>`
Parameters:
  `key` - Key to store in cache.
  `val` - Value to be associated with the given key.
Returns:
  Future of put operation which will provide previously contained value regardless of whether put happened or not.

#### putxIfAbsent

    public boolean putxIfAbsent(K key,
                       V val)
                         throws IgniteCheckedException

Stores given key-value pair in cache only if cache had no previous mapping for it.

This method will return `true` if value is stored in cache and `false` otherwise. Unlike `CacheProjection.putIfAbsent(Object, Object)` method, it does not return previous value and, therefore, does not have any overhead associated with returning of a value. It should always be used whenever return value is not required.

If write-through is enabled, the stored value will be persisted to `CacheStore` via `CacheStore#put(Transaction, Object, Object)` method.

## Transactions

This method is transactional and will enlist the entry into ongoing transaction if there is one.

## Cache Flags

This method is not available if any of the following flags are set on projection: `CacheFlag.LOCAL`, `CacheFlag.READ`.

Specified by:
  `putxIfAbsent` in interface `CacheProjection<K,V>`
Overrides:
  `putxIfAbsent` in class `GridCacheAdapter<K,V>`
Parameters:
  `key` - Key to store in cache.
  `val` - Value to be associated with the given key.
Returns:
  `true` if value is stored in cache and `false` otherwise.
Throws:
  `IgniteCheckedException` - If put operation failed.

#### putxIfAbsentAsync

    public IgniteInternalFuture<Boolean> putxIfAbsentAsync(K key,
                                                  V val)

Asynchronously stores given key-value pair in cache only if cache had no previous mapping for it.

This method will return `true` if value is stored in cache and `false` otherwise. Unlike `CacheProjection.putIfAbsent(Object, Object)` method, it does not return previous value and, therefore, does not have any overhead associated with returning of a value. It should always be used whenever return value is not required.

If write-through is enabled, the stored value will be persisted to `CacheStore` via `CacheStore#put(Transaction, Object, Object)` method.

## Transactions

This method is transactional and will enlist the entry into ongoing transaction if there is one.

## Cache Flags

This method is not available if any of the following flags are set on projection: `CacheFlag.LOCAL`, `CacheFlag.READ`.

Specified by:
  `putxIfAbsentAsync` in interface `CacheProjection<K,V>`
Overrides:
  `putxIfAbsentAsync` in class `GridCacheAdapter<K,V>`
Parameters:
  `key` - Key to store in cache.
  `val` - Value to be associated with the given key.
Returns:
  Future for this put operation.

#### replace

    public V replace(K key,
            V val)
              throws IgniteCheckedException

Stores given key-value pair in cache only if there is a previous mapping for it. In case of `CacheMode.PARTITIONED` or `CacheMode.REPLICATED` caches, the value will be loaded from the primary node, which in its turn may load the value from the swap storage, and consecutively, if it's not in swap, from the underlying persistent storage. If value has to be loaded from persistent storage, `CacheStore#load(Transaction, Object)` method will be used.

If the returned value is not needed, method `CacheProjection.replacex(Object, Object)` should always be used instead of this one to avoid the overhead associated with returning of the previous value.

If write-through is enabled, the stored value will be persisted to `CacheStore` via `CacheStore#put(Transaction, Object, Object)` method.

## Transactions

This method is transactional and will enlist the entry into ongoing transaction if there is one.

## Cache Flags

This method is not available if any of the following flags are set on projection: `CacheFlag.LOCAL`, `CacheFlag.READ`.

Specified by:
  `replace` in interface `CacheProjection<K,V>`
Overrides:
  `replace` in class `GridCacheAdapter<K,V>`
Parameters:
  `key` - Key to store in cache.
  `val` - Value to be associated with the given key.
Returns:
  Previously contained value regardless of whether replace happened or not.
Throws:
  `IgniteCheckedException` - If replace operation failed.

#### replaceAsync

    public IgniteInternalFuture<V> replaceAsync(K key,
                                       V val)

Asynchronously stores given key-value pair in cache only if there is a previous mapping for it. If cache previously contained value for the given key, then this value is returned.In case of `CacheMode.PARTITIONED` caches, the value will be loaded from the primary node, which in its turn may load the value from the swap storage, and consecutively, if it's not in swap, from the underlying persistent storage. If value has to be loaded from persistent storage, `CacheStore#load(Transaction, Object)` method will be used.

If the returned value is not needed, method `CacheProjection.replacex(Object, Object)` should always be used instead of this one to avoid the overhead associated with returning of the previous value.

If write-through is enabled, the stored value will be persisted to `CacheStore` via `CacheStore#put(Transaction, Object, Object)` method.

## Transactions

This method is transactional and will enlist the entry into ongoing transaction if there is one.

## Cache Flags

This method is not available if any of the following flags are set on projection: `CacheFlag.LOCAL`, `CacheFlag.READ`.

Specified by:
  `replaceAsync` in interface `CacheProjection<K,V>`
Overrides:
  `replaceAsync` in class `GridCacheAdapter<K,V>`
Parameters:
  `key` - Key to store in cache.
  `val` - Value to be associated with the given key.
Returns:
  Future for replace operation.

#### replacex

    public boolean replacex(K key,
                   V val)
                     throws IgniteCheckedException

Stores given key-value pair in cache only if only if there is a previous mapping for it.

This method will return `true` if value is stored in cache and `false` otherwise. Unlike `CacheProjection.replace(Object, Object)` method, it does not return previous value and, therefore, does not have any overhead associated with returning of a value. It should always be used whenever return value is not required.

If write-through is enabled, the stored value will be persisted to `CacheStore` via `CacheStore#put(Transaction, Object, Object)` method.

## Transactions

This method is transactional and will enlist the entry into ongoing transaction if there is one.

## Cache Flags

This method is not available if any of the following flags are set on projection: `CacheFlag.LOCAL`, `CacheFlag.READ`.

Specified by:
  `replacex` in interface `CacheProjection<K,V>`
Overrides:
  `replacex` in class `GridCacheAdapter<K,V>`
Parameters:
  `key` - Key to store in cache.
  `val` - Value to be associated with the given key.
Returns:
  `True` if replace happened, `false` otherwise.
Throws:
  `IgniteCheckedException` - If replace operation failed.

#### replacexAsync

    public IgniteInternalFuture<Boolean> replacexAsync(K key,
                                              V val)

Asynchronously stores given key-value pair in cache only if only if there is a previous mapping for it.

This method will return `true` if value is stored in cache and `false` otherwise. Unlike `CacheProjection.replaceAsync(Object, Object)` method, it does not return previous value and, therefore, does not have any overhead associated with returning of a value. It should always be used whenever return value is not required.

If write-through is enabled, the stored value will be persisted to `CacheStore` via `CacheStore#put(Transaction, Object, Object)` method.

## Transactions

This method is transactional and will enlist the entry into ongoing transaction if there is one.

## Cache Flags

This method is not available if any of the following flags are set on projection: `CacheFlag.LOCAL`, `CacheFlag.READ`.

Specified by:
  `replacexAsync` in interface `CacheProjection<K,V>`
Overrides:
  `replacexAsync` in class `GridCacheAdapter<K,V>`
Parameters:
  `key` - Key to store in cache.
  `val` - Value to be associated with the given key.
Returns:
  Future for the replace operation.

#### replace

    public boolean replace(K key,
                  V oldVal,
                  V newVal)
                    throws IgniteCheckedException

Stores given key-value pair in cache only if only if the previous value is equal to the `'oldVal'` passed in.

This method will return `true` if value is stored in cache and `false` otherwise.

If write-through is enabled, the stored value will be persisted to `CacheStore` via `CacheStore#put(Transaction, Object, Object)` method.

## Transactions

This method is transactional and will enlist the entry into ongoing transaction if there is one.

## Cache Flags

This method is not available if any of the following flags are set on projection: `CacheFlag.LOCAL`, `CacheFlag.READ`.

Specified by:
  `replace` in interface `CacheProjection<K,V>`
Overrides:
  `replace` in class `GridCacheAdapter<K,V>`
Parameters:
  `key` - Key to store in cache.
  `oldVal` - Old value to match.
  `newVal` - Value to be associated with the given key.
Returns:
  `True` if replace happened, `false` otherwise.
Throws:
  `IgniteCheckedException` - If replace operation failed.

#### replaceAsync

    public IgniteInternalFuture<Boolean> replaceAsync(K key,
                                             V oldVal,
                                             V newVal)

Asynchronously stores given key-value pair in cache only if only if the previous value is equal to the `'oldVal'` passed in.

This method will return `true` if value is stored in cache and `false` otherwise.

If write-through is enabled, the stored value will be persisted to `CacheStore` via `CacheStore#put(Transaction, Object, Object)` method.

## Transactions

This method is transactional and will enlist the entry into ongoing transaction if there is one.

## Cache Flags

This method is not available if any of the following flags are set on projection: `CacheFlag.LOCAL`, `CacheFlag.READ`.

Specified by:
  `replaceAsync` in interface `CacheProjection<K,V>`
Overrides:
  `replaceAsync` in class `GridCacheAdapter<K,V>`
Parameters:
  `key` - Key to store in cache.
  `oldVal` - Old value to match.
  `newVal` - Value to be associated with the given key.
Returns:
  Future for the replace operation.

#### removex

    public GridCacheReturn removex(K key,
                          V val)
                            throws IgniteCheckedException

Removes given key mapping from cache if one exists and value is equal to the passed in value.

If write-through is enabled, the value will be removed from `CacheStore` via `CacheWriter.delete(Object)` method.

## Transactions

This method is transactional and will enlist the entry into ongoing transaction if there is one.

## Cache Flags

This method is not available if any of the following flags are set on projection: `CacheFlag.LOCAL`, `CacheFlag.READ`.

Specified by:
  `removex` in interface `GridCacheProjectionEx<K,V>`
Overrides:
  `removex` in class `GridCacheAdapter<K,V>`
Parameters:
  `key` - Key whose mapping is to be removed from cache.
  `val` - Value to match against currently cached value.
Returns:
  Object containing actual old value and success flag.
Throws:
  `IgniteCheckedException` - If remove failed.

#### replacex

    public GridCacheReturn replacex(K key,
                           V oldVal,
                           V newVal)
                             throws IgniteCheckedException

Stores given key-value pair in cache only if only if the previous value is equal to the `'oldVal'` passed in.

This method will return `true` if value is stored in cache and `false` otherwise.

If write-through is enabled, the stored value will be persisted to `CacheStore` via `CacheWriter.write(javax.cache.Cache.Entry)` method.

## Transactions

This method is transactional and will enlist the entry into ongoing transaction if there is one.

## Cache Flags

This method is not available if any of the following flags are set on projection: `CacheFlag.LOCAL`, `CacheFlag.READ`.

Specified by:
  `replacex` in interface `GridCacheProjectionEx<K,V>`
Overrides:
  `replacex` in class `GridCacheAdapter<K,V>`
Parameters:
  `key` - Key to store in cache.
  `oldVal` - Old value to match.
  `newVal` - Value to be associated with the given key.
Returns:
  Object containing actual old value and success flag.
Throws:
  `IgniteCheckedException` - If replace operation failed.

#### removexAsync

    public IgniteInternalFuture<GridCacheReturn> removexAsync(K key,
                                                     V val)

Asynchronously removes given key mapping from cache if one exists and value is equal to the passed in value.

This method will return `true` if remove did occur, which means that all optionally provided filters have passed and there was something to remove, `false` otherwise.

If write-through is enabled, the value will be removed from `CacheStore` via `CacheWriter.delete(Object)` method.

## Transactions

This method is transactional and will enlist the entry into ongoing transaction if there is one.

## Cache Flags

This method is not available if any of the following flags are set on projection: `CacheFlag.LOCAL`, `CacheFlag.READ`.

Specified by:
  `removexAsync` in interface `GridCacheProjectionEx<K,V>`
Overrides:
  `removexAsync` in class `GridCacheAdapter<K,V>`
Parameters:
  `key` - Key whose mapping is to be removed from cache.
  `val` - Value to match against currently cached value.
Returns:
  Future for the remove operation. The future will return object containing actual old value and success flag.

#### replacexAsync

    public IgniteInternalFuture<GridCacheReturn> replacexAsync(K key,
                                                      V oldVal,
                                                      V newVal)

Asynchronously stores given key-value pair in cache only if only if the previous value is equal to the `'oldVal'` passed in.

This method will return `true` if value is stored in cache and `false` otherwise.

If write-through is enabled, the stored value will be persisted to `CacheStore` via `CacheWriter.write(javax.cache.Cache.Entry)` method.

## Transactions

This method is transactional and will enlist the entry into ongoing transaction if there is one.

## Cache Flags

This method is not available if any of the following flags are set on projection: `CacheFlag.LOCAL`, `CacheFlag.READ`.

Specified by:
  `replacexAsync` in interface `GridCacheProjectionEx<K,V>`
Overrides:
  `replacexAsync` in class `GridCacheAdapter<K,V>`
Parameters:
  `key` - Key to store in cache.
  `oldVal` - Old value to match.
  `newVal` - Value to be associated with the given key.
Returns:
  Future for the replace operation. The future will return object containing actual old value and success flag.

#### putAll

    public void putAll(Map<? extends K,? extends V> m,
              CacheEntryPredicate[] filter)
                throws IgniteCheckedException

Stores given key-value pairs in cache. If filters are provided, then entries will be stored in cache only if they pass the filter. Note that filter check is atomic, so value stored in cache is guaranteed to be consistent with the filters.

If write-through is enabled, the stored values will be persisted to `CacheStore` via `CacheStore#putAll(Transaction, Map)` method.

## Transactions

This method is transactional and will enlist the entry into ongoing transaction if there is one.

## Cache Flags

This method is not available if any of the following flags are set on projection: `CacheFlag.LOCAL`, `CacheFlag.READ`.

Specified by:
  `putAll` in interface `CacheProjection<K,V>`
Overrides:
  `putAll` in class `GridCacheAdapter<K,V>`
Parameters:
  `m` - Key-value pairs to store in cache.
  `filter` - Optional entry filter. If provided, then entry will be stored only if the filter returned `true`.
Throws:
  `IgniteCheckedException` - If put operation failed.

#### putAllAsync

    public IgniteInternalFuture<?> putAllAsync(Map<? extends K,? extends V> m,
                                      @Nullable
                                      CacheEntryPredicate[] filter)

Asynchronously stores given key-value pairs in cache. If filters are provided, then entries will be stored in cache only if they pass the filter. Note that filter check is atomic, so value stored in cache is guaranteed to be consistent with the filters.

If write-through is enabled, the stored values will be persisted to `CacheStore` via `CacheStore#putAll(Transaction, Map)` method.

## Transactions

This method is transactional and will enlist the entry into ongoing transaction if there is one.

## Cache Flags

This method is not available if any of the following flags are set on projection: `CacheFlag.LOCAL`, `CacheFlag.READ`.

Specified by:
  `putAllAsync` in interface `CacheProjection<K,V>`
Overrides:
  `putAllAsync` in class `GridCacheAdapter<K,V>`
Parameters:
  `m` - Key-value pairs to store in cache.
  `filter` - Optional entry filter. If provided, then entry will be stored only if the filter returned `true`.
Returns:
  Future for putAll operation.

#### putAllConflict

    public void putAllConflict(Map<KeyCacheObject,GridCacheDrInfo> conflictMap)
                        throws IgniteCheckedException

Store DR data.

Specified by:
  `putAllConflict` in interface `GridCacheProjectionEx<K,V>`
Overrides:
  `putAllConflict` in class `GridCacheAdapter<K,V>`
Parameters:
  `conflictMap` - DR map.
Throws:
  `IgniteCheckedException` - If put operation failed.

#### putAllConflictAsync

    public IgniteInternalFuture<?> putAllConflictAsync(Map<KeyCacheObject,GridCacheDrInfo> conflictMap)

Store DR data asynchronously.

Specified by:
  `putAllConflictAsync` in interface `GridCacheProjectionEx<K,V>`
Overrides:
  `putAllConflictAsync` in class `GridCacheAdapter<K,V>`
Parameters:
  `conflictMap` - DR map.
Returns:
  Future.

#### remove

    public V remove(K key,
           @Nullable
           GridCacheEntryEx entry,
           @Nullable
           CacheEntryPredicate... filter)
             throws IgniteCheckedException

Internal method that is called from `CacheEntryImpl`.

Specified by:
  `remove` in interface `GridCacheProjectionEx<K,V>`
Overrides:
  `remove` in class `GridCacheAdapter<K,V>`
Parameters:
  `key` - Key to remove.
  `entry` - Cached entry. If not provided, equivalent to {CacheProjection#put}.
  `filter` - Optional filter.
Returns:
  Previous value.
Throws:
  `IgniteCheckedException` - If failed.

#### removeAsync

    public IgniteInternalFuture<V> removeAsync(K key,
                                      @Nullable
                                      GridCacheEntryEx entry,
                                      @Nullable
                                      CacheEntryPredicate... filter)

Internal method that is called from `CacheEntryImpl`.

Specified by:
  `removeAsync` in interface `GridCacheProjectionEx<K,V>`
Overrides:
  `removeAsync` in class `GridCacheAdapter<K,V>`
Parameters:
  `key` - Key to remove.
  `entry` - Optional cached entry.
  `filter` - Optional filter.
Returns:
  Put operation future.

#### removeAll

    public void removeAll(Collection<? extends K> keys,
                 CacheEntryPredicate... filter)
                   throws IgniteCheckedException

Removes given key mappings from cache for entries for which the optionally passed in filters do pass.

If write-through is enabled, the values will be removed from `CacheStore` via `@link CacheStore#removeAll(Transaction, Collection)` method.

## Transactions

This method is transactional and will enlist the entry into ongoing transaction if there is one.

## Cache Flags

This method is not available if any of the following flags are set on projection: `CacheFlag.LOCAL`, `CacheFlag.READ`.

Specified by:
  `removeAll` in interface `CacheProjection<K,V>`
Overrides:
  `removeAll` in class `GridCacheAdapter<K,V>`
Parameters:
  `keys` - Keys whose mappings are to be removed from cache.
  `filter` - Optional filter to check prior to removing value form cache. Note that filter is checked atomically together with remove operation.
Throws:
  `IgniteCheckedException` - If remove failed.

#### removeAllAsync

    public IgniteInternalFuture<?> removeAllAsync(Collection<? extends K> keys,
                                         CacheEntryPredicate[] filter)

Asynchronously removes given key mappings from cache for entries for which the optionally passed in filters do pass.

If write-through is enabled, the values will be removed from `CacheStore` via `@link CacheStore#removeAll(Transaction, Collection)` method.

## Transactions

This method is transactional and will enlist the entry into ongoing transaction if there is one.

## Cache Flags

This method is not available if any of the following flags are set on projection: `CacheFlag.LOCAL`, `CacheFlag.READ`.

Specified by:
  `removeAllAsync` in interface `CacheProjection<K,V>`
Overrides:
  `removeAllAsync` in class `GridCacheAdapter<K,V>`
Parameters:
  `keys` - Keys whose mappings are to be removed from cache.
  `filter` - Optional filter to check prior to removing value form cache. Note that filter is checked atomically together with remove operation.
Returns:
  Future for the remove operation. The future will complete whenever remove operation completes.

#### removex

    public boolean removex(K key,
                  @Nullable
                  GridCacheEntryEx entry,
                  @Nullable
                  CacheEntryPredicate... filter)
                    throws IgniteCheckedException

Internal method that is called from `CacheEntryImpl`.

Specified by:
  `removex` in interface `GridCacheProjectionEx<K,V>`
Overrides:
  `removex` in class `GridCacheAdapter<K,V>`
Parameters:
  `key` - Key to remove.
  `entry` - Cached entry. If not provided, equivalent to {CacheProjection#put}.
  `filter` - Optional filter.
Returns:
  Previous value.
Throws:
  `IgniteCheckedException` - If failed.

#### removexAsync

    public IgniteInternalFuture<Boolean> removexAsync(K key,
                                             @Nullable
                                             GridCacheEntryEx entry,
                                             @Nullable
                                             CacheEntryPredicate... filter)

Internal method that is called from `CacheEntryImpl`.

Specified by:
  `removexAsync` in interface `GridCacheProjectionEx<K,V>`
Overrides:
  `removexAsync` in class `GridCacheAdapter<K,V>`
Parameters:
  `key` - Key to remove.
  `entry` - Cached entry. If not provided, equivalent to {CacheProjection#put}.
  `filter` - Optional filter.
Returns:
  Putx operation future.

#### remove

    public boolean remove(K key,
                 V val)
                   throws IgniteCheckedException

Removes given key mapping from cache if one exists and value is equal to the passed in value.

If write-through is enabled, the value will be removed from `CacheStore` via `CacheStore#remove(Transaction, Object)` method.

## Transactions

This method is transactional and will enlist the entry into ongoing transaction if there is one.

## Cache Flags

This method is not available if any of the following flags are set on projection: `CacheFlag.LOCAL`, `CacheFlag.READ`.

Specified by:
  `remove` in interface `CacheProjection<K,V>`
Overrides:
  `remove` in class `GridCacheAdapter<K,V>`
Parameters:
  `key` - Key whose mapping is to be removed from cache.
  `val` - Value to match against currently cached value.
Returns:
  `True` if entry was removed and passed in value matched the cached one, `false` otherwise.
Throws:
  `IgniteCheckedException` - If remove failed.

#### removeAsync

    public IgniteInternalFuture<Boolean> removeAsync(K key,
                                            V val)

Asynchronously removes given key mapping from cache if one exists and value is equal to the passed in value.

This method will return `true` if remove did occur, which means that all optionally provided filters have passed and there was something to remove, `false` otherwise.

If write-through is enabled, the value will be removed from `CacheStore` via `CacheStore#remove(Transaction, Object)` method.

## Transactions

This method is transactional and will enlist the entry into ongoing transaction if there is one.

## Cache Flags

This method is not available if any of the following flags are set on projection: `CacheFlag.LOCAL`, `CacheFlag.READ`.

Specified by:
  `removeAsync` in interface `CacheProjection<K,V>`
Overrides:
  `removeAsync` in class `GridCacheAdapter<K,V>`
Parameters:
  `key` - Key whose mapping is to be removed from cache.
  `val` - Value to match against currently cached value.
Returns:
  Future for the remove operation. The future will return `true` if currently cached value will match the passed in one.

#### localRemoveAll

    public void localRemoveAll()
                        throws IgniteCheckedException

Specified by:
  `localRemoveAll` in interface `CacheProjection<K,V>`
Overrides:
  `localRemoveAll` in class `GridCacheAdapter<K,V>`
Throws:
  `IgniteCheckedException` - If failed.

#### localRemoveAll

    public IgniteInternalFuture<?> localRemoveAll(CacheEntryPredicate filter)

Overrides:
  `localRemoveAll` in class `GridCacheAdapter<K,V>`
Parameters:
  `filter` - Filter.
Returns:
  Future.

#### removeAllConflict

    public void removeAllConflict(Map<KeyCacheObject,GridCacheVersion> conflictMap)
                           throws IgniteCheckedException

Removes DR data.

Specified by:
  `removeAllConflict` in interface `GridCacheProjectionEx<K,V>`
Overrides:
  `removeAllConflict` in class `GridCacheAdapter<K,V>`
Parameters:
  `conflictMap` - DR map.
Throws:
  `IgniteCheckedException` - If remove failed.

#### removeAllConflictAsync

    public IgniteInternalFuture<?> removeAllConflictAsync(Map<KeyCacheObject,GridCacheVersion> conflictMap)

Removes DR data asynchronously.

Specified by:
  `removeAllConflictAsync` in interface `GridCacheProjectionEx<K,V>`
Overrides:
  `removeAllConflictAsync` in class `GridCacheAdapter<K,V>`
Parameters:
  `conflictMap` - DR map.
Returns:
  Future.

#### asyncOp

    protected <T> IgniteInternalFuture<T> asyncOp(CO<IgniteInternalFuture<T>> op)

Parameters:
  `op` - Operation closure.
Returns:
  Future.

#### lockAllAsync

    protected IgniteInternalFuture<Boolean> lockAllAsync(Collection<KeyCacheObject> keys,
                                             long timeout,
                                             @Nullable
                                             IgniteTxLocalEx tx,
                                             boolean isInvalidate,
                                             boolean isRead,
                                             boolean retval,
                                             @Nullable
                                             TransactionIsolation isolation,
                                             long accessTtl,
                                             CacheEntryPredicate[] filter)

Specified by:
  `lockAllAsync` in class `GridDistributedCacheAdapter<K,V>`
Parameters:
  `keys` - Keys to lock.
  `timeout` - Timeout.
  `tx` - Transaction
  `isInvalidate` - Invalidation flag.
  `isRead` - Indicates whether value is read or written.
  `retval` - Flag to return value.
  `isolation` - Transaction isolation.
  `accessTtl` - TTL for read operation.
  `filter` - Optional filter.
Returns:
  Future for locks.

#### invoke

    public <T> javax.cache.processor.EntryProcessorResult<T> invoke(K key,
                                                           javax.cache.processor.EntryProcessor<K,V,T> entryProcessor,
                                                           Object... args)
                                                         throws IgniteCheckedException

Specified by:
  `invoke` in interface `GridCacheProjectionEx<K,V>`
Overrides:
  `invoke` in class `GridCacheAdapter<K,V>`
Parameters:
  `key` - Key.
  `entryProcessor` - Entry processor.
  `args` - Arguments.
Returns:
  Invoke result.
Throws:
  `IgniteCheckedException` - If failed.

#### invokeAll

    public <T> Map<K,javax.cache.processor.EntryProcessorResult<T>> invokeAll(Set<? extends K> keys,
                                                                     javax.cache.processor.EntryProcessor<K,V,T> entryProcessor,
                                                                     Object... args)
                                                                   throws IgniteCheckedException

Specified by:
  `invokeAll` in interface `GridCacheProjectionEx<K,V>`
Overrides:
  `invokeAll` in class `GridCacheAdapter<K,V>`
Parameters:
  `keys` - Keys.
  `entryProcessor` - Entry processor.
  `args` - Arguments.
Returns:
  Invoke results.
Throws:
  `IgniteCheckedException` - If failed.

#### invokeAsync

    public <T> IgniteInternalFuture<javax.cache.processor.EntryProcessorResult<T>> invokeAsync(K key,
                                                                                      javax.cache.processor.EntryProcessor<K,V,T> entryProcessor,
                                                                                      Object... args)

Specified by:
  `invokeAsync` in interface `GridCacheProjectionEx<K,V>`
Overrides:
  `invokeAsync` in class `GridCacheAdapter<K,V>`
Parameters:
  `key` - Key.
  `entryProcessor` - Entry processor.
  `args` - Arguments.
Returns:
  Future.

#### invokeAllAsync

    public <T> IgniteInternalFuture<Map<K,javax.cache.processor.EntryProcessorResult<T>>> invokeAllAsync(Set<? extends K> keys,
                                                                                                javax.cache.processor.EntryProcessor<K,V,T> entryProcessor,
                                                                                                Object... args)

Specified by:
  `invokeAllAsync` in interface `GridCacheProjectionEx<K,V>`
Overrides:
  `invokeAllAsync` in class `GridCacheAdapter<K,V>`
Parameters:
  `keys` - Keys.
  `entryProcessor` - Entry processor.
  `args` - Arguments.
Returns:
  Future.

#### invokeAll

    public <T> Map<K,javax.cache.processor.EntryProcessorResult<T>> invokeAll(Map<? extends K,? extends javax.cache.processor.EntryProcessor<K,V,T>> map,
                                                                     Object... args)
                                                                   throws IgniteCheckedException

Specified by:
  `invokeAll` in interface `GridCacheProjectionEx<K,V>`
Overrides:
  `invokeAll` in class `GridCacheAdapter<K,V>`
Parameters:
  `map` - Map containing keys and entry processors to be applied to values.
  `args` - Arguments.
Returns:
  Invoke results.
Throws:
  `IgniteCheckedException` - If failed.

#### invokeAllAsync

    public <T> IgniteInternalFuture<Map<K,javax.cache.processor.EntryProcessorResult<T>>> invokeAllAsync(Map<? extends K,? extends javax.cache.processor.EntryProcessor<K,V,T>> map,
                                                                                                Object... args)

Specified by:
  `invokeAllAsync` in interface `GridCacheProjectionEx<K,V>`
Overrides:
  `invokeAllAsync` in class `GridCacheAdapter<K,V>`
Parameters:
  `map` - Map containing keys and entry processors to be applied to values.
  `args` - Arguments.
Returns:
  Future.

#### updateAllAsyncInternal

    public void updateAllAsyncInternal(UUID nodeId,
                              GridNearAtomicUpdateRequest req,
                              CI2<GridNearAtomicUpdateRequest,GridNearAtomicUpdateResponse> completionCb)

Executes local update.

Parameters:
  `nodeId` - Node ID.
  `req` - Update request.
  `completionCb` - Completion callback.

#### updateAllAsyncInternal0

    public void updateAllAsyncInternal0(UUID nodeId,
                               GridNearAtomicUpdateRequest req,
                               CI2<GridNearAtomicUpdateRequest,GridNearAtomicUpdateResponse> completionCb)

Executes local update after preloader fetched values.

Parameters:
  `nodeId` - Node ID.
  `req` - Update request.
  `completionCb` - Completion callback.

#### toString

    public String toString()

Overrides:
  `toString` in class `GridDhtCacheAdapter<K,V>`

2015 Copyright © Apache Software Foundation

Follow @ApacheIgnite

Ignite Fabric | : ver. 1.0.0
Release Date | : March 31 2015