VMware VMware GemFire Native .NET Reference 10.4.3
Loading...
Searching...
No Matches
Apache::Geode::Client::IGeodeCache Interface Reference

GeodeCache represents the singleton cache that must be created in order to connect to Geode server. More...

#include <IGeodeCache.hpp>

Inherits Apache::Geode::Client::IRegionService.

Inherited by Apache::Geode::Client::Cache.

Public Member Functions

void Close ()
 Terminates this object cache and releases all the local resources.
 
IPdxInstanceFactoryCreatePdxInstanceFactory (String^ className)
 Returns a factory that can create a PdxInstance.
 
bool GetPdxIgnoreUnreadFields ()
 summary> Returns whether PdxInstance is preferred for PDX types instead of .NET object.
 
Client::QueryServiceGetQueryService ()
 Get a query service object to be able to query the cache.
 
template<class TKey , class TValue >
IRegion< TKey, TValue > ^ GetRegion (String^ name)
 Returns an existing region given the full path from root, or null if no such region exists.
 
void InitializeDeclarativeCache (String^ cacheXml)
 Initializes the cache from an XML file.
 
template<class TKey , class TValue >
array< IRegion< TKey, TValue >^> ^ RootRegions ()
 Returns an array of root regions in the cache.
 

Properties

Apache::Geode::Client::CacheTransactionManagerCacheTransactionManager [get]
 Returns the cache transaction manager of CacheFactory.Create this cache.
 
bool IsClosed [get]
 True if this cache has been closed.
 
String^ Name [get]
 Returns the name of this cache.
 

Detailed Description

GeodeCache represents the singleton cache that must be created in order to connect to Geode server.

Caches are obtained from Crest methods on the CacheFactory.Create class.

When a cache is created a DistributedSystem must be specified.

When a cache will no longer be used, call Cache.Close. Once it Cache.IsClosed any attempt to use it will cause a CacheClosedException to be thrown.

A cache can have multiple root regions, each with a different name.

Member Function Documentation

◆ Close()

void Apache::Geode::Client::IRegionService::Close ( )
inherited

Terminates this object cache and releases all the local resources.

If RegionService is created from Cache.CreateAuthenticatedView, then it clears user related security data.

After this cache is closed, any further method call on this cache or any region object will throw CacheClosedException, unless otherwise noted.

Exceptions
CacheClosedExceptionif the cache is already closed.

Implemented in Apache::Geode::Client::Cache.

◆ CreatePdxInstanceFactory()

IPdxInstanceFactory ^ Apache::Geode::Client::IRegionService::CreatePdxInstanceFactory ( String^  className)
inherited

Returns a factory that can create a PdxInstance.

Parameters
classNamethe fully qualified class name that the PdxInstance will become when it is fully deserialized.
Returns
the factory

Implemented in Apache::Geode::Client::Cache.

◆ GetPdxIgnoreUnreadFields()

bool Apache::Geode::Client::IGeodeCache::GetPdxIgnoreUnreadFields ( )

summary> Returns whether PdxInstance is preferred for PDX types instead of .NET object.

/summary>

Implemented in Apache::Geode::Client::Cache.

◆ GetQueryService()

Client::QueryService ^ Apache::Geode::Client::IRegionService::GetQueryService ( )
inherited

Get a query service object to be able to query the cache.

Currently only works against the java server in native mode, and at least some endpoints must have been defined in some regions before actually firing a query.

Implemented in Apache::Geode::Client::Cache.

◆ GetRegion()

template<class TKey , class TValue >
IRegion< TKey, TValue > ^ Apache::Geode::Client::IRegionService::GetRegion ( String^  name)
inherited

Returns an existing region given the full path from root, or null if no such region exists.

Parameters
namethe name of the region
Returns
the region

Implemented in Apache::Geode::Client::Cache.

◆ InitializeDeclarativeCache()

void Apache::Geode::Client::IGeodeCache::InitializeDeclarativeCache ( String^  cacheXml)

Initializes the cache from an XML file.

Parameters
cacheXmlpathname of a cache.xml file

Implemented in Apache::Geode::Client::Cache.

◆ RootRegions()

template<class TKey , class TValue >
array< IRegion< TKey, TValue >^> ^ Apache::Geode::Client::IRegionService::RootRegions ( )
inherited

Returns an array of root regions in the cache.

This set is a snapshot and is not backed by the cache.

It is not supported when Cache is created from Pool.

Returns
array of regions

Implemented in Apache::Geode::Client::Cache.

Property Documentation

◆ CacheTransactionManager

Apache:: Geode:: Client:: CacheTransactionManager^ Apache::Geode::Client::IGeodeCache::CacheTransactionManager
get

Returns the cache transaction manager of CacheFactory.Create this cache.

summary> Returns whether Cache saves unread fields for Pdx types. /summary>

◆ IsClosed

bool Apache::Geode::Client::IRegionService::IsClosed
getinherited

True if this cache has been closed.

After a new cache object is created, this method returns false. After Close is called on this cache object, this method returns true.

Returns
true if this cache is closed, otherwise false

◆ Name

String^ Apache::Geode::Client::IGeodeCache::Name
get

Returns the name of this cache.

This method does not throw CacheClosedException if the cache is closed.

Returns
the string name of this cache

Apache Geode C++ Cache .NET API Documentation