CMS 3D CMS Logo

edm::Timestamp Class Reference

#include <DataFormats/Provenance/interface/Timestamp.h>

List of all members.

Public Member Functions

bool operator!= (const Timestamp &iRHS) const
bool operator< (const Timestamp &iRHS) const
bool operator<= (const Timestamp &iRHS) const
bool operator== (const Timestamp &iRHS) const
bool operator> (const Timestamp &iRHS) const
bool operator>= (const Timestamp &iRHS) const
 Timestamp ()
 Timestamp (TimeValue_t iValue)
TimeValue_t value () const
virtual ~Timestamp ()

Static Public Member Functions

static const TimestampbeginOfTime ()
static const TimestampendOfTime ()
static const TimestampinvalidTimestamp ()

Private Attributes

unsigned int timeHigh_
unsigned int timeLow_


Detailed Description

Definition at line 29 of file Timestamp.h.


Constructor & Destructor Documentation

Timestamp::Timestamp ( TimeValue_t  iValue  ) 

Definition at line 33 of file Timestamp.cc.

00033                                        : 
00034    timeLow_(static_cast<unsigned int>(kLowMask & iValue)),
00035    timeHigh_(static_cast<unsigned int>(iValue >> 32))
00036 {
00037 }

Timestamp::Timestamp (  ) 

Definition at line 39 of file Timestamp.cc.

Timestamp::~Timestamp (  )  [virtual]

Definition at line 48 of file Timestamp.cc.

00049 {
00050 }


Member Function Documentation

const Timestamp & Timestamp::beginOfTime (  )  [static]

Definition at line 96 of file Timestamp.cc.

Referenced by edm::DaqSource::DaqSource(), and edm::RawInputSource::RawInputSource().

00096                        {
00097    static Timestamp s_beginOfTime(1);
00098    return s_beginOfTime;
00099 }

const Timestamp & Timestamp::endOfTime (  )  [static]

Definition at line 88 of file Timestamp.cc.

References pyDBSRunClass::temp.

Referenced by EcalTrivialConditionRetriever::produceEcalLaserAPDPNRatios(), and publishObjects().

00088                      {
00089    //calculate 2^N -1 where N is number of bits in TimeValue_t
00090    // by doing 2^(N-1) - 1 + 2^(N-1)
00091    const TimeValue_t temp = TimeValue_t(1) << (sizeof(TimeValue_t)/sizeof(char) * 8 - 1);
00092    static Timestamp s_endOfTime((temp -1) + temp);
00093    return s_endOfTime;
00094 }

const Timestamp & Timestamp::invalidTimestamp (  )  [static]

Definition at line 83 of file Timestamp.cc.

Referenced by edm::conversion(), edm::StreamerInputSource::deserializeEvent(), edm::LuminosityBlockAuxiliary::mergeAuxiliary(), edm::RunAuxiliary::mergeNewTimestampsIntoThis_(), edm::RootFile::readLumi(), edm::RawInputSource::readLuminosityBlock_(), edm::ConfigurableInputSource::readLuminosityBlock_(), edm::RootFile::readRun(), edm::RawInputSource::readRun_(), edm::ConfigurableInputSource::readRun_(), edm::LuminosityBlockAuxiliary::setEndTime(), and edm::RunAuxiliary::setEndTime().

00083                             {
00084    static Timestamp s_invalid(0);
00085    return s_invalid;
00086 }

bool edm::Timestamp::operator!= ( const Timestamp iRHS  )  const [inline]

Definition at line 45 of file Timestamp.h.

00045                                                    {
00046          return !(*this == iRHS);
00047       }

bool edm::Timestamp::operator< ( const Timestamp iRHS  )  const [inline]

Definition at line 49 of file Timestamp.h.

References timeHigh_, and timeLow_.

00049                                                   {
00050          if(timeHigh_ == iRHS.timeHigh_) {
00051             return timeLow_ < iRHS.timeLow_;
00052          }
00053          return timeHigh_ < iRHS.timeHigh_;
00054       }

bool edm::Timestamp::operator<= ( const Timestamp iRHS  )  const [inline]

Definition at line 55 of file Timestamp.h.

References timeHigh_, and timeLow_.

00055                                                    {
00056          if(timeHigh_ == iRHS.timeHigh_) {
00057             return timeLow_ <= iRHS.timeLow_;
00058          }
00059          return timeHigh_ <= iRHS.timeHigh_;
00060       }

bool edm::Timestamp::operator== ( const Timestamp iRHS  )  const [inline]

Definition at line 41 of file Timestamp.h.

References timeHigh_, and timeLow_.

00041                                                    {
00042          return timeHigh_ == iRHS.timeHigh_ &&
00043          timeLow_ == iRHS.timeLow_;
00044       }

bool edm::Timestamp::operator> ( const Timestamp iRHS  )  const [inline]

Definition at line 61 of file Timestamp.h.

References timeHigh_, and timeLow_.

00061                                                   {
00062          if(timeHigh_ == iRHS.timeHigh_) {
00063             return timeLow_ > iRHS.timeLow_;
00064          }
00065          return timeHigh_ > iRHS.timeHigh_;
00066       }

bool edm::Timestamp::operator>= ( const Timestamp iRHS  )  const [inline]

Definition at line 67 of file Timestamp.h.

References timeHigh_, and timeLow_.

00067                                                    {
00068          if(timeHigh_ == iRHS.timeHigh_) {
00069             return timeLow_ >= iRHS.timeLow_;
00070          }
00071          return timeHigh_ >= iRHS.timeHigh_;
00072       }

TimeValue_t Timestamp::value (  )  const

Definition at line 72 of file Timestamp.cc.

Referenced by SiStripGainFromData::algoAnalyze(), XmasToDQMEventInfo::analyze(), EcalTrivialObjectAnalyzer::analyze(), DQMEventInfo::analyze(), EcalGetLaserData::analyze(), HcalMonitorModule::analyze(), RPCEfficiencyFromTrack::analyze(), HcalMonitorClient::analyze(), RPCMonitorSync::analyze(), VisEvent::analyze(), DQMEventInfo::beginRun(), XmasToDQMEventInfo::beginRun(), DQMEventMsgBuilder::DQMEventMsgBuilder(), EcalLaserDbService::getLaserCorrection(), VisEventIdTwig::onNewEvent(), edm::service::Tracer::preBeginLumi(), edm::service::Tracer::preBeginRun(), edm::service::Tracer::preEndLumi(), edm::service::Tracer::preEndRun(), edm::service::Tracer::preEvent(), cond::service::PoolDBOutputService::preEventProcessing(), EcalTrivialConditionRetriever::produceEcalLaserAPDPNRatios(), EcalTrivialConditionRetriever::setIntervalFor(), edm::AsciiOutputModule::write(), SiPixelHistoricInfoEDAClient::writetoDB(), and HistoricOfflineClient::writeToDB().

00072                        {
00073    TimeValue_t returnValue = timeHigh_;
00074    returnValue = returnValue << 32;
00075    returnValue += timeLow_;
00076    return returnValue;
00077 }


Member Data Documentation

unsigned int edm::Timestamp::timeHigh_ [private]

Definition at line 90 of file Timestamp.h.

Referenced by operator<(), operator<=(), operator==(), operator>(), and operator>=().

unsigned int edm::Timestamp::timeLow_ [private]

Definition at line 89 of file Timestamp.h.

Referenced by operator<(), operator<=(), operator==(), operator>(), and operator>=().


The documentation for this class was generated from the following files:
Generated on Tue Jun 9 18:44:25 2009 for CMSSW by  doxygen 1.5.4