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

CdbBdbObject.hh

Go to the documentation of this file.
00001 #ifndef CDBBDB_OBJECT_HH
00002 #define CDBBDB_OBJECT_HH
00003 
00004 // File and Version Information:
00005 //      $Id: CdbBdbObject.hh,v 1.11 2005/09/15 05:06:25 gapon Exp $
00006 
00007 #include "CdbBase/CdbObject.hh"
00008 
00009 #include "BdbCond/BdbObject.hh"
00010 
00011 /// This class implements an abstract base class CdbObject
00012 /**
00013   * It's a "wrapper" implementation on the top of the old Condition/DB API.
00014   *
00015   * @see CdbObject
00016   */
00017 class CdbBdbObject : public CdbObject {
00018 
00019 friend class CdbBdbObjectCreator;   // Who creates me.
00020 
00021 private:
00022 
00023   /// The default constructor (NOT IMPLEMENTED)
00024   /**
00025     * Is disabled...
00026     */
00027     CdbBdbObject( );
00028 
00029   /// The copy constructor (NOT IMPLEMENTED)
00030   /**
00031     * Is disabled...
00032     */
00033     CdbBdbObject( const CdbBdbObject& theObject );
00034 
00035   /// The assignment operator (NOT IMPLEMENTED)
00036   /**
00037     * Is disabled...
00038     */
00039     CdbBdbObject& operator=( const CdbBdbObject& theObject );
00040 
00041 protected:
00042 
00043   /// The normal constructor...
00044   /**
00045     * More details...
00046     */
00047     CdbBdbObject( const CdbConditionPtr&      theConditionPtr,      /**< the smart pointer providing a back back link to the parent condition object */
00048                   const BdbTime&              theBeginOriginalValidity,
00049                   const BdbTime&              theEndOriginalValidity,
00050                   const BdbTime&              theBeginValidity,
00051                   const BdbTime&              theEndValidity,
00052                   const BdbTime&              theBeginDuration,
00053                   const BdbTime&              theEndDuration,
00054                   const BdbTime&              theInsertionTime,
00055                   const BdbHandle(BdbObject)& thePersObj            /**< a handle of a persistent object */
00056                 );
00057 
00058   /// The destructor.
00059   /**
00060     * Is only available for the derived classes and friends to prevent accidental
00061     * deletion of objects.
00062     */
00063     virtual ~CdbBdbObject( );
00064 
00065 public:
00066 
00067   /// Get the object reference
00068   /**
00069     * @returns a const reference onto the stored persistent reference
00070     */
00071     const BdbRef(BdbObject)& objectRef( ) const;
00072 
00073   /// An object identifier
00074   /**
00075     * Implements the corresponding method from the base class.
00076     *
00077     * @see CdbObject::id()
00078     */
00079     virtual std::string id( ) const;
00080 
00081   /// A 'legacy' object identifier
00082   /**
00083     * Implements the corresponding method from the base class.
00084     *
00085     * @see CdbObject::legacyId()
00086     */
00087     virtual std::string legacyId( ) const;
00088 
00089   /// A persistent type name
00090   /**
00091     * Implements the corresponding method from the base class.
00092     *
00093     * @see CdbObject::type()
00094     */
00095     virtual std::string type( ) const;
00096 
00097 private:
00098 
00099     BdbRef(BdbObject) _objectRef;
00100 };
00101 
00102 #endif  // CDBBDB_OBJECT_HH

Generated on Mon Dec 5 18:22:00 2005 for CDB by doxygen1.3-rc3