Hitachi

In-Memory Data Grid Hitachi Elastic Application Data Store


20.1.3 ead_start_cache() (starts access to the cache)

Organization of this subsection

(1) Description

This function starts access to the cache and obtains a handle (pointer) for accessing the specified cache.

(2) Format

#include <eads.h>
EAD_CACHE  *ead_start_cache
(
  const EAD_CACHE_MANAGER *cmp,                /* In */
  const char              *cache_name,         /* In */
  int                     *error_code          /* Out */
);

(3) Arguments

cmp

Specifies the handle (pointer) to the cache manager that is managing the cache.

Specify a handle obtained from ead_init_client() or ead_init_client_n().

cache_name

Specifies the name of the cache to be accessed.

For details about the data types that can be specified, see 15.2.2(4) Data types that can be specified as cache names.

error_code

Specifies the pointer from which to retrieve the error code.

For details about error codes, see 20.2 Error codes in the client library (C).

(4) Return value

If ead_start_cache() terminates normally, it returns a handle (pointer) to the specified cache.

If ead_start_cache() terminates abnormally, it returns NULL.

(5) Notes

To terminate access to the cache, execute ead_stop_cache().