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

CdbBdb2RooPayloadMrgConverter< P, R > Class Template Reference

The specialized generic "P-R" abstract base class for user defined (merging) converters. More...

#include <CdbBdb2RooPayloadMrgConverter.hh>

Inheritance diagram for CdbBdb2RooPayloadMrgConverter< P, R >:

CdbBdb2RooPayloadConverter< P, R > CdbRooConverterBase List of all members.

Public Member Functions

virtual ~CdbBdb2RooPayloadMrgConverter ()
 The destructor.


Protected Member Functions

 CdbBdb2RooPayloadMrgConverter ()
 The default constructor.

 CdbBdb2RooPayloadMrgConverter (const CdbBdb2RooPayloadMrgConverter< P, R > &theOther)
 The copy constructor.

CdbBdb2RooPayloadMrgConverter<
P, R > & 
operator= (const CdbBdb2RooPayloadMrgConverter< P, R > &theOther)
 The assignment operator.

virtual CdbStatus userDefinedConversion (const BdbRef(BdbObject)&theMainInputObjectRef, const std::vector< BdbRef(BdbObject) > &theExtraObjectsList, R *&theOutputObjectPtr) const=0
 Implement a user-defined conversion (merged version).


Detailed Description

template<class P, class R>
class CdbBdb2RooPayloadMrgConverter< P, R >

The specialized generic "P-R" abstract base class for user defined (merging) converters.

This base class allows to build "merging" converters which are supposed to construct an output objects out of more than one input objects. Here is how to build user defined converters based on this paradigme:

1. A user defined converter should derived from the current class using the public inheritance.

2. The user defined converter should implement the "userDefinedConversion()" conversion method re-defined below with an extended signature.

3. The list of extra objects passed to the conversion method will contain at least one object. The actual number and types of objects will depend on a use and on an implementation of a particular converter.

Definition at line 29 of file CdbBdb2RooPayloadMrgConverter.hh.


Constructor & Destructor Documentation

template<class P, class R>
CdbBdb2RooPayloadMrgConverter< P, R >::CdbBdb2RooPayloadMrgConverter   [protected]
 

The default constructor.

See also:
CdbBdb2RooPayloadConverter::CdbBdb2RooPayloadConverter()

Definition at line 14 of file CdbBdb2RooPayloadMrgConverter.cc.

template<class P, class R>
CdbBdb2RooPayloadMrgConverter< P, R >::CdbBdb2RooPayloadMrgConverter const CdbBdb2RooPayloadMrgConverter< P, R > &    theOther [protected]
 

The copy constructor.

Definition at line 20 of file CdbBdb2RooPayloadMrgConverter.cc.

template<class P, class R>
CdbBdb2RooPayloadMrgConverter< P, R >::~CdbBdb2RooPayloadMrgConverter   [virtual]
 

The destructor.

Definition at line 26 of file CdbBdb2RooPayloadMrgConverter.cc.


Member Function Documentation

template<class P, class R>
CdbBdb2RooPayloadMrgConverter< P, R > & CdbBdb2RooPayloadMrgConverter< P, R >::operator= const CdbBdb2RooPayloadMrgConverter< P, R > &    theOther [protected]
 

The assignment operator.

Definition at line 33 of file CdbBdb2RooPayloadMrgConverter.cc.

References CdbBdb2RooPayloadConverter< P, R >::operator=().

template<class P, class R>
virtual CdbStatus CdbBdb2RooPayloadMrgConverter< P, R >::userDefinedConversion const BdbRef(BdbObject)&    theMainInputObjectRef,
const std::vector< BdbRef(BdbObject) > &    theExtraObjectsList,
R *&    theOutputObjectPtr
const [protected, pure virtual]
 

Implement a user-defined conversion (merged version).

This pure virtual method is supposed to be implemented by subclasses for the specified (in the constructor) pair of classes. However, unlike its regular version this one will also take a list of extra objects to be merged with the main input object to produce an output object. The list is guranteed to have at least one extra object. An actual number of extra objects depends on a particular use and an implementation of a user defined converter. It's also defined during a database conversion planing.

The method will be invoked by the above implemented "::userDefinedConversion()" method.

The method is supposed to return CdbStatus::Success in case of its successfull completion, or any other value otherwise, which will be treated as a failure. Also when a call is successfull then the ouput object pointer must be filled with a valid pointer onto a nely created object.

NOTES:

1. The output object's ownership is also expected to be returned with the object.

2. The method has the same name as for the "one-to-one" conversion, but it has a different signature.

See also:
CdbBdb2RooPayloadMrgConverter::CdbBdb2RooPayloadMrgConverter()

CdbBdb2RooPayloadMrgConverter::userDefinedConversion()


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