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

CdbSQLApi Class Reference

The starting point for the public API of the Conditions/DB. More...

#include <CdbSQLApi.hh>

Inheritance diagram for CdbSQLApi:

Cdb CdbRooDb List of all members.

Public Member Functions

virtual ~CdbSQLApi ()
 The destructor.

virtual CdbStatus createObject (CdbObjectPtr &theObjectPtr, const CdbConditionPtr &theParentConditionPtr, const BdbTime &theOriginalValidityBeginTime, const BdbTime &theOriginalValidityEndTime, const BdbTime &theVisibleValidityBeginTime, const BdbTime &theVisibleValidityEndTime, const BdbTime &theDurationBeginTime, const BdbTime &theDurationEndTime, const BdbTime &theInsertionTime, const CdbSQLObjectId &theObjectId)=0
 Create a metadata object of a right type.

virtual CdbStatus storeObject (CdbObjectPtr &theObjectPtr, CdbObjectFactoryBase &theObjectFactory, CdbCPtr< CdbSQLCondition > &thePersistentConditionPtr, CdbCPtr< CdbSQLPartition > &thePersistentPartitionPtr, const CdbConditionPtr &theParentConditionPtr, const BdbTime &theOriginalValidityBeginTime, const BdbTime &theOriginalValidityEndTime)=0
 Create a persistent object (in the specified context) and store it in a database.


Protected Member Functions

 CdbSQLApi ()
 The default constructor.


Detailed Description

The starting point for the public API of the Conditions/DB.

The only reason to have this abtsract class in the hierarchy is that it provides the "::createObject()" meant to deffer an actual object creation sequence by a subclass down the hierarchy. That allows final implementations of the current API class to instantiate objects (those produced by the above mentioned method) of correct types.

A general idea is that we have enough data at the current level to create new objects but we don't know types of that objects.

NOTE: A similar idea would be to define a method delivering a factory interface. This could even work at a higher level of this class's hierarchy (class Cdb).

See also:
CdbSQLApi::createObject()

Cdb

CdbEnvironment

Definition at line 36 of file CdbSQLApi.hh.


Constructor & Destructor Documentation

CdbSQLApi::CdbSQLApi   [protected]
 

The default constructor.

The c-tor is only availble to subclasses.

Definition at line 12 of file CdbSQLApi.cc.

CdbSQLApi::~CdbSQLApi   [virtual]
 

The destructor.

More details...

Definition at line 16 of file CdbSQLApi.cc.


Member Function Documentation

virtual CdbStatus CdbSQLApi::createObject CdbObjectPtr   theObjectPtr,
const CdbConditionPtr   theParentConditionPtr,
const BdbTime   theOriginalValidityBeginTime,
const BdbTime   theOriginalValidityEndTime,
const BdbTime   theVisibleValidityBeginTime,
const BdbTime   theVisibleValidityEndTime,
const BdbTime   theDurationBeginTime,
const BdbTime   theDurationEndTime,
const BdbTime   theInsertionTime,
const CdbSQLObjectId   theObjectId
[pure virtual]
 

Create a metadata object of a right type.

This method is meant to defer the actual operation to a more specialized implementation of the current class. This way we let that (specialized) implementation to decide on an object type.

The method is supposed to be implemented by a subclass.

See also:
CdbObject

CdbCondition

CdbSQLObjectId

Returns:
CdbStatus::Success if the operation succeeds

Implemented in CdbRooDb.

virtual CdbStatus CdbSQLApi::storeObject CdbObjectPtr   theObjectPtr,
CdbObjectFactoryBase   theObjectFactory,
CdbCPtr< CdbSQLCondition > &    thePersistentConditionPtr,
CdbCPtr< CdbSQLPartition > &    thePersistentPartitionPtr,
const CdbConditionPtr   theParentConditionPtr,
const BdbTime   theOriginalValidityBeginTime,
const BdbTime   theOriginalValidityEndTime
[pure virtual]
 

Create a persistent object (in the specified context) and store it in a database.

This method is meant to defer the actual operation to a more specialized implementation of the current class. This way we let that (specialized) implementation to decide on an object type.

The method is supposed to be implemented by a subclass.

See also:
CdbObject

CdbCondition

Returns:
CdbStatus::Success if the operation succeeds

Implemented in CdbRooDb.

Referenced by CdbSQLApiCondition::storeObject().


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