CkptSimpleContainer< T > Class Template Reference

Templated container for typesafe access to objects stored in CKPT. More...

#include <CkptContainer.h>

Inheritance diagram for CkptSimpleContainer< T >:

CkptContainer List of all members.

Public Member Functions

 CkptSimpleContainer (std::string containerName, unsigned long maxObjects, unsigned long maxObjectSize, CkptRetentionPolicy rPolicy=CKPT_RELEASE)
T * get (CkptObjectKey *key)
 Retrieve a representation of the object identified by a key.
T * get (CkptObjectKey &key)
 Retrieve a representation of the object identified by a key.

Detailed Description

template<class T>
class CkptSimpleContainer< T >

Templated container for typesafe access to objects stored in CKPT.

Limits a container to a single class type, ensuring typesafe retrieval

Definition at line 176 of file CkptContainer.h.


Constructor & Destructor Documentation

template<class T>
CkptSimpleContainer< T >::CkptSimpleContainer ( std::string  containerName,
unsigned long  maxObjects,
unsigned long  maxObjectSize,
CkptRetentionPolicy  rPolicy = CKPT_RELEASE 
) [inline]

Definition at line 178 of file CkptContainer.h.


Member Function Documentation

template<class T>
T* CkptSimpleContainer< T >::get ( CkptObjectKey key  )  [inline]

Retrieve a representation of the object identified by a key.

CAUTION: calling this procedure with the pointer to a stack-based key can result in faults (if the retrieved object outlives the stack frame where the key resides)

Parameters:
key - the key for the object being retrieved
Returns:
a pointer to the CkptObject associated with key.
  • This object is a snapshot representation of the data in the underlying replica.
  • Commits to the container by other nodes do not cause automatic update to this object.
See also:
get(CkptObjectKey&)

Reimplemented from CkptContainer.

Definition at line 184 of file CkptContainer.h.

References CkptContainer::get().

template<class T>
T* CkptSimpleContainer< T >::get ( CkptObjectKey key  )  [inline]

Retrieve a representation of the object identified by a key.

The key is COPIED, and the copy is owned by the retrieved CkptObject through a call to CkptObject::setKey() To use a non-stack-based key (say, on a heap), and to avoid the copy, use get(CkptObjectKey*)

Parameters:
key - the key for the object being retrieved
Returns:
a pointer to the CkptObject associated with key.
  • This object is a snapshot representation of the data in the underlying replica.
  • Commits to the container by other nodes do not cause automatic updates to this object.
See also:
get(CkptObjectKey*)

Reimplemented from CkptContainer.

Definition at line 187 of file CkptContainer.h.

References CkptContainer::get().


The documentation for this class was generated from the following file:
Generated on Fri Apr 27 17:20:02 2007 for aiscoal by  doxygen 1.5.2