gemfire::RegionEntry Class Reference

Inherits gemfire::SharedBase.


Detailed Description

An object in a Region that represents an entry, i.e., a key-value pair.

This object's operations are not distributed, do not acquire any locks, and do not affect CacheStatistics.

Unless otherwise noted, all of these methods throw a CacheClosedException if the Cache is closed at the time of invocation, or an EntryDestroyedException if the entry has been destroyed.

Public Member Functions

CacheableKeyPtr getKey ()
 Returns the key for this entry.
void getRegion (RegionPtr &region)
 Returns the region that contains this entry.
void getStatistics (CacheStatisticsPtr &csptr)
 Returns the statistics for this entry.
CacheablePtr getValue ()
 Returns the value of this entry in the local cache.
bool isDestroyed () const
 Returns whether this entry has been destroyed.
void preserveSB () const
 Atomically increment reference count.
int32_t refCount ()
 
Returns:
the reference count

void releaseSB () const
 Atomically decrement reference count, the SharedBase object is automatically deleted when its reference count goes to zero.
virtual ~RegionEntry ()


Constructor & Destructor Documentation

virtual gemfire::RegionEntry::~RegionEntry (  )  [virtual]

destructor


Member Function Documentation

CacheableKeyPtr gemfire::RegionEntry::getKey (  ) 

Returns the key for this entry.

Returns:
the key for this entry

void gemfire::RegionEntry::getRegion ( RegionPtr region  ) 

Returns the region that contains this entry.

Returns:
the Region that contains this entry

void gemfire::RegionEntry::getStatistics ( CacheStatisticsPtr csptr  ) 

Returns the statistics for this entry.

Returns:
the CacheStatistics for this entry
Exceptions:
StatisticsDisabledException if statistics have been disabled for this region

CacheablePtr gemfire::RegionEntry::getValue (  ) 

Returns the value of this entry in the local cache.

Does not invoke a CacheLoader,

Returns:
the value or NULLPTR if this entry is invalid

bool gemfire::RegionEntry::isDestroyed (  )  const

Returns whether this entry has been destroyed.

Does not throw a EntryDestroyedException if this entry has been destroyed.

Returns:
true if this entry has been destroyed

void gemfire::SharedBase::preserveSB (  )  const [inherited]

Atomically increment reference count.

int32_t gemfire::SharedBase::refCount (  )  [inline, inherited]

Returns:
the reference count

void gemfire::SharedBase::releaseSB (  )  const [inherited]

Atomically decrement reference count, the SharedBase object is automatically deleted when its reference count goes to zero.


GemFire C++ Cache API Documentation