Main Page   Namespace List   Class Hierarchy   Compound List   File List   Namespace Members   Compound Members   File Members  

CdbBdbNTupleConversionImpl< T, NCOL, ELEMENT_CONVERSION_RULES > Class Template Reference

The generic implementation of the conversion facility. More...

#include <CdbBdbNTupleConversionImpl.hh>

List of all members.

Static Public Member Functions

CdbStatus to_transient (CdbCPtr< CdbNTuple< T, NCOL > > &thePtr, const ooRef(BdbObject)&thePersRef)
 Convert a persistent object to the transient form.

CdbStatus to_transient (CdbNTuple< T, NCOL > *&thePtr, const ooRef(BdbObject)&thePersRef)
 Convert a persistent object to the transient form (regular pointer version).

CdbStatus to_persistent (ooRef(BdbObject)&thePersRef, const CdbCPtr< CdbNTuple< T, NCOL > > &thePtr, const BdbRefAny &theHintRef)
 Convert a transient object to the persistent form.


Detailed Description

template<class T, unsigned int NCOL, class ELEMENT_CONVERSION_RULES>
class CdbBdbNTupleConversionImpl< T, NCOL, ELEMENT_CONVERSION_RULES >

The generic implementation of the conversion facility.

IMPLEMENTATION NOTE:

The current implementation of this factory will support only predefined "primitive types" of elements. A mechanizm of expened support for arbitrary (or user defined) types of elements will be added later.

USAGE NOTES:

Users are discouraged to use this API directly as its interface or implementation is likely to change. Another reason not to use this class is its "heavy" template interface.

The current package has a number of "fron-end" classes with more stable and much simple API.

Definition at line 35 of file CdbBdbNTupleConversionImpl.hh.


Member Function Documentation

template<class T, unsigned int NCOL, class ELEMENT_CONVERSION_RULES>
CdbStatus CdbBdbNTupleConversionImpl< T, NCOL, ELEMENT_CONVERSION_RULES >::to_persistent ooRef(BdbObject)&    thePersRef,
const CdbCPtr< CdbNTuple< T, NCOL > > &    thePtr,
const BdbRefAny &    theHintRef
[static]
 

Convert a transient object to the persistent form.

If successuful, the method would initialize the persistent reference to point onto a newely created persistent table (of unspecified here actual implentation) filled with data and metadata copied from the specified transient table.

If any kind of error will happen then the persistent pointer is guaranteed to stay intact.

REQUIREMENTS:

(1) The persistent table must have the same actual type and configurations (number of columns) as the transient one.

(2) The corresponding vortual tables for the persistnt class must be properly loaded.

(3) The type of elements of a persistent typle would be derived from the type converter policy supplied (or default) as a template parameter of the class.

(4) Should the transient and persistent types of elements be different the corresponding conversion must exist and be provided through the supplied (or default) converter policy.

Definition at line 287 of file CdbBdbNTupleConversionImpl.cc.

Referenced by CdbBdbNTupleT2P< ELEMENT_CONVERSION_RULES >::convert().

template<class T, unsigned int NCOL, class ELEMENT_CONVERSION_RULES>
CdbStatus CdbBdbNTupleConversionImpl< T, NCOL, ELEMENT_CONVERSION_RULES >::to_transient CdbNTuple< T, NCOL > *&    thePtr,
const ooRef(BdbObject)&    thePersRef
[static]
 

Convert a persistent object to the transient form (regular pointer version).

Definition at line 273 of file CdbBdbNTupleConversionImpl.cc.

template<class T, unsigned int NCOL, class ELEMENT_CONVERSION_RULES>
CdbStatus CdbBdbNTupleConversionImpl< T, NCOL, ELEMENT_CONVERSION_RULES >::to_transient CdbCPtr< CdbNTuple< T, NCOL > > &    thePtr,
const ooRef(BdbObject)&    thePersRef
[static]
 

Convert a persistent object to the transient form.

If successuful, the method would initialize the smart pointer to point onto a newely created transient table (of unspecified here actual implentation) filled with data and metadata copied from the specified persistent table.

If any kind of error will happen then the transient pointer is guaranteed to stay intact.

REQUIREMENTS:

(1) The persistent table must have the same actual type and configurations (number of columns) as the transient one.

(2) The corresponding vortual tables for the persistnt class must be properly loaded.

(3) The type of elements of a persistent typle would be derived from the type converter policy supplied (or default) as a template parameter of the class.

(4) Should the transient and persistent types of elements be different the corresponding conversion must exist and be provided through the supplied (or default) converter policy.

Definition at line 258 of file CdbBdbNTupleConversionImpl.cc.

References CdbStatus::Success.

Referenced by CdbBdbNTupleP2T< ELEMENT_CONVERSION_RULES >::convert().


The documentation for this class was generated from the following files:
Generated on Mon Dec 5 18:22:17 2005 for CDB by doxygen1.3-rc3