Oracle® Fusion Middleware C++ API Reference for Oracle Coherence
12c (12.2.1.3.0)

E80355-01

BundlingNamedCache Class Reference

#include <coherence/net/cache/BundlingNamedCache.hpp>

Inherits WrapperNamedCache.

List of all members.


Detailed Description

Bundling NamedCache implementation.

See also:
AbstractBundler
Author:
gg 2007.02.13

lh 2012.06.05

Since:
Coherence 12.1.2

Public Types

typedef spec::Handle Handle
 BundlingNamedCache Handle definition.
typedef spec::View View
 BundlingNamedCache View definition.
typedef spec::Holder Holder
 BundlingNamedCache Holder definition.
typedef this_spec::Handle Handle
 WrapperNamedCache Handle definition.
typedef this_spec::View View
 WrapperNamedCache View definition.
typedef this_spec::Holder Holder
 WrapperNamedCache Holder definition.

Public Member Functions

virtual
AbstractBundler::Handle 
ensureGetBundler (int32_t cBundleThreshold)
 Configure the bundler for the "get" operations.
virtual
AbstractBundler::Handle 
ensurePutBundler (int32_t cBundleThreshold)
 Configure the bundler for the "put" operations.
virtual
AbstractBundler::Handle 
ensureRemoveBundler (int32_t cBundleThreshold)
 Configure the bundler for the "remove" operations.
virtual
AbstractBundler::Handle 
getGetBundler ()
 Obtain the bundler for the "get" operations.
virtual
AbstractBundler::Handle 
getPutBundler ()
 Obtain the bundler for the "put" operations.
virtual
AbstractBundler::Handle 
getRemoveBundler ()
 Obtain the bundler for the "remove" operations.
virtual Object::Holder get (Object::View vKey)
 Return the value to which this map maps the specified key.

Return NULL if the map contains no mapping for this key. A return value of NULL does not necessarily indicate that the map contains no mapping for the key; it's also possible that the map explicitly maps the key to NULL. The containsKey operation may be used to distinguish these two cases.

Parameters:
vKey key whose associated value is to be returned.
Returns:
the value to which this map maps the specified key, or NULL if the map contains no mapping for this key.
See also:
containsKey()

virtual Map::View getAll (Collection::View vColKeys)
 
virtual Object::Holder put (Object::View vKey, Object::Holder ohValue)
 Associate the specified value with the specified key in this map.

If the map previously contained a mapping for this key, the old value is replaced by the specified value.

Parameters:
vKey key with which the specified value is to be associated.
ohValue value to be associated with the specified key.
Returns:
previous value associated with specified key, or NULL if there was no mapping for key. A NULL return can also indicate that the map previously associated NULL with the specified key.
Exceptions:
coherence::lang::UnsupportedOperationException if the put() operation is not supported by this map.

virtual void putAll (Map::View vMap)
 
virtual Object::Holder remove (Object::View vKey)
 Remove the mapping for this key from this map if it is present.

Return the value to which the map previously associated the key, or NULL if the map contained no mapping for this key. (A NULL return can also indicate that the map previously associated NULL with the specified key.) The map will not contain a mapping for the specified key once the call returns.

Parameters:
vKey key whose mapping is to be removed from the map.
Returns:
previous value associated with specified key, or NULL if there was no mapping for key.
Exceptions:
coherence::lang::UnsupportedOperationException if the remove() operation is not supported by this map.

virtual void release ()
 Release local resources associated with this instance of NamedCache.

Releasing a cache makes it no longer usable, but does not affect the cache itself. In other words, all other references to the cache will still be valid, and the cache data is not affected by releasing the reference. Any attempt to use this reference afterward will result in an exception.

Caches should be released by the same mechanism in which they were obtained. For example:

Except for the case where the application code explicitly allocated the cache, this method should not be called by application code.

See also:
CacheFactory::releaseCache

ConfigurableCacheFactory::releaseCache


virtual void destroy ()
 Release and destroy this instance of NamedCache.

Warning: This method is used to completely destroy the specified cache across the cluster. All references in the entire cluster to this cache will be invalidated, the cached data will be cleared, and all resources will be released.

Caches should be destroyed by the same mechanism in which they were obtained. For example:

Except for the case where the application code explicitly allocated the cache, this method should not be called by application code.

See also:
CacheService::destroyCache


Protected Member Functions

 BundlingNamedCache (NamedCache::Handle hCache)
 Construct a BundlingNamedCache based on the specified NamedCache.

Constructor & Destructor Documentation

BundlingNamedCache ( NamedCache::Handle  hCache  )  [protected]

Construct a BundlingNamedCache based on the specified NamedCache.

Parameters:
hCache the NamedCache that will be wrapped by this BundlingNamedCache


Member Function Documentation

virtual AbstractBundler::Handle ensureGetBundler ( int32_t  cBundleThreshold  )  [virtual]

Configure the bundler for the "get" operations.

If the bundler does not exist and bundling is enabled, it will be instantiated.

Parameters:
cBundleThreshold the bundle size threshold; pass zero to disable "get" operation bundling
Returns:
the "get" bundler or NULL if bundling is disabled

virtual AbstractBundler::Handle ensurePutBundler ( int32_t  cBundleThreshold  )  [virtual]

Configure the bundler for the "put" operations.

If the bundler does not exist and bundling is enabled, it will be instantiated.

Parameters:
cBundleThreshold the bundle size threshold; pass zero to disable "put" operation bundling
Returns:
the "put" bundler or NULL if bundling is disabled

virtual AbstractBundler::Handle ensureRemoveBundler ( int32_t  cBundleThreshold  )  [virtual]

Configure the bundler for the "remove" operations.

If the bundler does not exist and bundling is enabled, it will be instantiated.

Parameters:
cBundleThreshold the bundle size threshold; pass zero to disable "remove" operation bundling
Returns:
the "remove" bundler or NULL if bundling is disabled

virtual AbstractBundler::Handle getGetBundler (  )  [virtual]

Obtain the bundler for the "get" operations.

Returns:
the "get" bundler

virtual AbstractBundler::Handle getPutBundler (  )  [virtual]

Obtain the bundler for the "put" operations.

Returns:
the "put" bundler

virtual AbstractBundler::Handle getRemoveBundler (  )  [virtual]

Obtain the bundler for the "remove" operations.

Returns:
the "remove" bundler

virtual Object::Holder put ( Object::View  vKey,
Object::Holder  ohValue 
) [virtual]

Associate the specified value with the specified key in this map.

If the map previously contained a mapping for this key, the old value is replaced by the specified value.

Parameters:
vKey key with which the specified value is to be associated.
ohValue value to be associated with the specified key.
Returns:
previous value associated with specified key, or NULL if there was no mapping for key. A NULL return can also indicate that the map previously associated NULL with the specified key.
Exceptions:
coherence::lang::UnsupportedOperationException if the put() operation is not supported by this map.

Note: this method always returns NULL.

Reimplemented from WrapperNamedCache.

virtual Object::Holder remove ( Object::View  vKey  )  [virtual]

Remove the mapping for this key from this map if it is present.

Return the value to which the map previously associated the key, or NULL if the map contained no mapping for this key. (A NULL return can also indicate that the map previously associated NULL with the specified key.) The map will not contain a mapping for the specified key once the call returns.

Parameters:
vKey key whose mapping is to be removed from the map.
Returns:
previous value associated with specified key, or NULL if there was no mapping for key.
Exceptions:
coherence::lang::UnsupportedOperationException if the remove() operation is not supported by this map.

Note: this method always returns NULL.

Reimplemented from WrapperNamedCache.


The documentation for this class was generated from the following file:
Copyright © 2000, 2017, Oracle and/or its affiliates. All rights reserved.