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

CdbBdbNTupleP2T< ELEMENT_CONVERSION_RULES > Class Template Reference

A front-end class for "persistent-to-transient" conversion facility. More...

#include <CdbBdbNTupleP2T.hh>

List of all members.

Static Public Member Functions

template<class T, unsigned int NCOL> CdbStatus convert (CdbCPtr< CdbNTuple< T, NCOL > > &thePtr, const ooRef(BdbObject)&thePersRef)
 Try to convert (from a persistent reference).

template<class T, unsigned int NCOL> CdbStatus convert (CdbNTuple< T, NCOL > *&thePtr, const ooRef(BdbObject)&thePersRef)
 Try to convert (from a persistent reference) (regular pointer version).

template<class T, unsigned int NCOL> CdbStatus convert (CdbCPtr< CdbNTuple< T, NCOL > > &thePtr, const CdbObjectPtr &theObjectPtr)
 Try to convert (from a generic CdbObject).

template<class T, unsigned int NCOL> CdbStatus convert (CdbNTuple< T, NCOL > *&thePtr, const CdbObjectPtr &theObjectPtr)
 Try to convert (from a generic CdbObject) (regular pointer version).


Detailed Description

template<class ELEMENT_CONVERSION_RULES = CdbBdbNTupleConversionRules_UseDefault>
class CdbBdbNTupleP2T< ELEMENT_CONVERSION_RULES >

A front-end class for "persistent-to-transient" conversion facility.

DESCRIPTION:

This class is meant to be used as a primary API for user's code who needs to convert a persistent n-tuple into the corresponding transient form. The convertor's design allows to avoid passing explicit template parameters of (both transient and persistent) n-tuples.

Note that this is a template class having template method(s). The only parameter of the template class is:

ELEMENT_CONVERSION_RULES

which is a policy for user defined element conversion. The policy is meant to help in situations when there is no straight-forward mapping between transient and persistent types of elements, or in cases when a user wishes to pack rather small transient types (bit strings, enums, etc.) into bigger persistent elements.

NOTE: this way of transient-to-persistent and vs. transformation of elements has its own "pros" and "cons".

By default the conversion facility uses default rules for elements conversion. See class's specialization below.

See also:
class CdbNTupleConversionImpl

class CdbBdbNTupleConversionRules_UseDefault

class CdbBdbNTupleConversionRules_Default

Definition at line 45 of file CdbBdbNTupleP2T.hh.


Member Function Documentation

template<class ELEMENT_CONVERSION_RULES = CdbBdbNTupleConversionRules_UseDefault>
template<class T, unsigned int NCOL>
CdbStatus CdbBdbNTupleP2T< ELEMENT_CONVERSION_RULES >::convert CdbNTuple< T, NCOL > *&    thePtr,
const CdbObjectPtr   theObjectPtr
[inline, static]
 

Try to convert (from a generic CdbObject) (regular pointer version).

Definition at line 100 of file CdbBdbNTupleP2T.hh.

References CdbBdbNTupleP2T< ELEMENT_CONVERSION_RULES >::convert(), CdbBdbObjectConvertor::narrow(), and CdbStatus::Success.

template<class ELEMENT_CONVERSION_RULES = CdbBdbNTupleConversionRules_UseDefault>
template<class T, unsigned int NCOL>
CdbStatus CdbBdbNTupleP2T< ELEMENT_CONVERSION_RULES >::convert CdbCPtr< CdbNTuple< T, NCOL > > &    thePtr,
const CdbObjectPtr   theObjectPtr
[inline, static]
 

Try to convert (from a generic CdbObject).

Unlike the above defined method this one accepts a smart pointer onto a "generic" metadata object representing a persistent object at the level of the transient CDB API.

See also:
CdbBdbNTupleConversionImpl::to_transient()

class CdbBdbObjectConvertor

Definition at line 84 of file CdbBdbNTupleP2T.hh.

References CdbBdbNTupleP2T< ELEMENT_CONVERSION_RULES >::convert(), CdbBdbObjectConvertor::narrow(), and CdbStatus::Success.

template<class ELEMENT_CONVERSION_RULES = CdbBdbNTupleConversionRules_UseDefault>
template<class T, unsigned int NCOL>
CdbStatus CdbBdbNTupleP2T< ELEMENT_CONVERSION_RULES >::convert CdbNTuple< T, NCOL > *&    thePtr,
const ooRef(BdbObject)&    thePersRef
[inline, static]
 

Try to convert (from a persistent reference) (regular pointer version).

Definition at line 66 of file CdbBdbNTupleP2T.hh.

References CdbBdbNTupleConversionImpl< T, NCOL, ELEMENT_CONVERSION_RULES >::to_transient().

template<class ELEMENT_CONVERSION_RULES = CdbBdbNTupleConversionRules_UseDefault>
template<class T, unsigned int NCOL>
CdbStatus CdbBdbNTupleP2T< ELEMENT_CONVERSION_RULES >::convert CdbCPtr< CdbNTuple< T, NCOL > > &    thePtr,
const ooRef(BdbObject)&    thePersRef
[inline, static]
 

Try to convert (from a persistent reference).

See also:
CdbBdbNTupleConversionImpl::to_transient()

Definition at line 55 of file CdbBdbNTupleP2T.hh.

References CdbBdbNTupleConversionImpl< T, NCOL, ELEMENT_CONVERSION_RULES >::to_transient().

Referenced by CdbBdbNTupleP2T< ELEMENT_CONVERSION_RULES >::convert(), and CdbBdbNTupleProxy< T, NCOL >::redefinedFaultHandler().


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