emcOMTimeStamp Class Reference

#include <emcOMTimeStamp.h>

Inherits emcObjectManager.

Inheritance diagram for emcOMTimeStamp:

Inheritance graph
[legend]
List of all members.

Detailed Description

Object to wrap the access to RunToTimePg and cache results.

Definition at line 14 of file emcOMTimeStamp.h.

Public Member Functions

 emcOMTimeStamp (const char *name="", const char *title="")
virtual ~emcOMTimeStamp ()
virtual bool CanCollect (const emcManageable &) const
virtual bool CanRead (const emcManageable &object) const
 Can we read a given object type ?
virtual bool CanWrite (const emcManageable &) const
 Can we write a given object type ?
virtual emcManageableCollect (const emcManageable &, const PHTimeStamp &)
virtual bool Read (emcManageable &, const PHTimeStamp &, int)
 Read a manageable object from the DB.
virtual bool Read (emcManageable &object, int runnumber)
 Read a manageable object from the DB.
virtual void Reset (void)
 Reset the OM.
virtual bool Write (const emcManageable &, const PHTimeStamp &, int=-1)
 Write a manageable object to the DB.

Private Attributes

std::map< int, PHTimeStamp * > fTSMap


Constructor & Destructor Documentation

emcOMTimeStamp::emcOMTimeStamp const char *  name = "",
const char *  title = ""
 

Definition at line 9 of file emcOMTimeStamp.C.

emcOMTimeStamp::~emcOMTimeStamp  )  [virtual]
 

Definition at line 15 of file emcOMTimeStamp.C.

References Reset().


Member Function Documentation

virtual bool emcOMTimeStamp::CanCollect const emcManageable  )  const [inline, virtual]
 

Deprecated:
Can we collect such object ?
Returns:
false by default.

Reimplemented from emcObjectManager.

Definition at line 21 of file emcOMTimeStamp.h.

bool emcOMTimeStamp::CanRead const emcManageable object  )  const [virtual]
 

Can we read a given object type ?

Returns:
false by default.

Reimplemented from emcObjectManager.

Definition at line 22 of file emcOMTimeStamp.C.

References emcManageable::GetSource(), emcManageable::kDB_Pg, and test().

virtual bool emcOMTimeStamp::CanWrite const emcManageable  )  const [inline, virtual]
 

Can we write a given object type ?

Returns:
false by default.

Reimplemented from emcObjectManager.

Definition at line 26 of file emcOMTimeStamp.h.

virtual emcManageable* emcOMTimeStamp::Collect const emcManageable ,
const PHTimeStamp & 
[inline, virtual]
 

Deprecated:
Collect a manageable from the DB. See the DM interface for parameters. Unless allowed explicitely by a particular Object Manager, in general the returned pointer (should not be deleted) by the receiver !

Has been deprecated because handling of collections is better done elsewhere. That's not the job of the datamanager, after all...

Reimplemented from emcObjectManager.

Definition at line 29 of file emcOMTimeStamp.h.

bool emcOMTimeStamp::Read emcManageable object,
int  runnumber
[virtual]
 

Read a manageable object from the DB.

See the DM interface for parameters.

Reimplemented from emcObjectManager.

Definition at line 39 of file emcOMTimeStamp.C.

References fTSMap, and emcTimeStamp::setTimeStamp().

virtual bool emcOMTimeStamp::Read emcManageable ,
const PHTimeStamp &  ,
int 
[inline, virtual]
 

Read a manageable object from the DB.

See the DM interface for parameters.

Implements emcObjectManager.

Definition at line 33 of file emcOMTimeStamp.h.

void emcOMTimeStamp::Reset void   )  [virtual]
 

Reset the OM.

After a call to Reset, the OM must behave as if it was newly created.

Implements emcObjectManager.

Definition at line 70 of file emcOMTimeStamp.C.

References fTSMap.

Referenced by ~emcOMTimeStamp().

virtual bool emcOMTimeStamp::Write const emcManageable ,
const PHTimeStamp &  ,
int  = -1
[inline, virtual]
 

Write a manageable object to the DB.

See the DM interface for parameters.

Implements emcObjectManager.

Definition at line 42 of file emcOMTimeStamp.h.


Member Data Documentation

std::map<int,PHTimeStamp*> emcOMTimeStamp::fTSMap [private]
 

Definition at line 48 of file emcOMTimeStamp.h.

Referenced by Read(), and Reset().


The documentation for this class was generated from the following files: