CMS 3D CMS Logo

List of all members | Public Member Functions | Private Member Functions | Private Attributes | Friends
edm::RunAuxiliary Class Reference

#include <RunAuxiliary.h>

Public Member Functions

Timestamp const & beginTime () const
 
Timestamp const & endTime () const
 
RunID const & id () const
 
RunIDid ()
 
void mergeAuxiliary (RunAuxiliary const &aux)
 
ProcessHistoryID const & processHistoryID () const
 
RunNumber_t run () const
 
 RunAuxiliary ()
 
 RunAuxiliary (RunID const &theId, Timestamp const &theTime, Timestamp const &theEndTime)
 
 RunAuxiliary (RunNumber_t const &run, Timestamp const &theTime, Timestamp const &theEndTime)
 
void setBeginTime (Timestamp const &time)
 
void setEndTime (Timestamp const &time)
 
void setProcessHistoryID (ProcessHistoryID const &phid)
 
void write (std::ostream &os) const
 
 ~RunAuxiliary ()
 

Private Member Functions

void mergeNewTimestampsIntoThis_ (RunAuxiliary const &newAux)
 

Private Attributes

Timestamp beginTime_
 
Timestamp endTime_
 
RunID id_
 
ProcessHistoryID processHistoryID_
 

Friends

void conversion (RunAux const &, RunAuxiliary &)
 

Detailed Description

Definition at line 15 of file RunAuxiliary.h.

Constructor & Destructor Documentation

◆ RunAuxiliary() [1/3]

edm::RunAuxiliary::RunAuxiliary ( )
inline

Definition at line 18 of file RunAuxiliary.h.

ProcessHistoryID processHistoryID_
Definition: RunAuxiliary.h:46
Timestamp endTime_
Definition: RunAuxiliary.h:52
Timestamp beginTime_
Definition: RunAuxiliary.h:51

◆ RunAuxiliary() [2/3]

edm::RunAuxiliary::RunAuxiliary ( RunID const &  theId,
Timestamp const &  theTime,
Timestamp const &  theEndTime 
)
inline

Definition at line 19 of file RunAuxiliary.h.

20  : processHistoryID_(), id_(theId), beginTime_(theTime), endTime_(theEndTime) {}
ProcessHistoryID processHistoryID_
Definition: RunAuxiliary.h:46
Timestamp endTime_
Definition: RunAuxiliary.h:52
Timestamp beginTime_
Definition: RunAuxiliary.h:51

◆ RunAuxiliary() [3/3]

edm::RunAuxiliary::RunAuxiliary ( RunNumber_t const &  run,
Timestamp const &  theTime,
Timestamp const &  theEndTime 
)
inline

Definition at line 21 of file RunAuxiliary.h.

22  : processHistoryID_(), id_(run), beginTime_(theTime), endTime_(theEndTime) {}
ProcessHistoryID processHistoryID_
Definition: RunAuxiliary.h:46
RunNumber_t run() const
Definition: RunAuxiliary.h:31
Timestamp endTime_
Definition: RunAuxiliary.h:52
Timestamp beginTime_
Definition: RunAuxiliary.h:51

◆ ~RunAuxiliary()

edm::RunAuxiliary::~RunAuxiliary ( )
inline

Definition at line 23 of file RunAuxiliary.h.

23 {}

Member Function Documentation

◆ beginTime()

Timestamp const& edm::RunAuxiliary::beginTime ( ) const
inline

◆ endTime()

Timestamp const& edm::RunAuxiliary::endTime ( ) const
inline

◆ id() [1/2]

RunID const& edm::RunAuxiliary::id ( ) const
inline

Definition at line 27 of file RunAuxiliary.h.

References id_.

Referenced by L1GtUtils::getL1GtRunCache(), edm::RunBase::id(), edm::RunForOutput::id(), and edm::RunPrincipal::id().

27 { return id_; }

◆ id() [2/2]

RunID& edm::RunAuxiliary::id ( )
inline

Definition at line 28 of file RunAuxiliary.h.

References id_.

28 { return id_; }

◆ mergeAuxiliary()

void edm::RunAuxiliary::mergeAuxiliary ( RunAuxiliary const &  aux)

Definition at line 15 of file RunAuxiliary.cc.

References cms::cuda::assert(), id_, and mergeNewTimestampsIntoThis_().

15  {
16  assert(id_ == newAux.id_);
18  }
assert(be >=bs)
void mergeNewTimestampsIntoThis_(RunAuxiliary const &newAux)
Definition: RunAuxiliary.cc:20

◆ mergeNewTimestampsIntoThis_()

void edm::RunAuxiliary::mergeNewTimestampsIntoThis_ ( RunAuxiliary const &  newAux)
private

Definition at line 20 of file RunAuxiliary.cc.

References beginTime(), beginTime_, endTime(), endTime_, and edm::Timestamp::invalidTimestamp().

Referenced by mergeAuxiliary().

20  {
21  if (beginTime_ == Timestamp::invalidTimestamp() || newAux.beginTime() == Timestamp::invalidTimestamp()) {
23  } else if (newAux.beginTime() < beginTime_) {
24  beginTime_ = newAux.beginTime();
25  }
26 
27  if (endTime_ == Timestamp::invalidTimestamp() || newAux.endTime() == Timestamp::invalidTimestamp()) {
29  } else if (newAux.endTime() > endTime_) {
30  endTime_ = newAux.endTime();
31  }
32  }
static Timestamp invalidTimestamp()
Definition: Timestamp.h:82
Timestamp endTime_
Definition: RunAuxiliary.h:52
Timestamp beginTime_
Definition: RunAuxiliary.h:51

◆ processHistoryID()

ProcessHistoryID const& edm::RunAuxiliary::processHistoryID ( ) const
inline

Definition at line 25 of file RunAuxiliary.h.

References processHistoryID_.

Referenced by fwlite::Run::history().

25 { return processHistoryID_; }
ProcessHistoryID processHistoryID_
Definition: RunAuxiliary.h:46

◆ run()

RunNumber_t edm::RunAuxiliary::run ( ) const
inline

◆ setBeginTime()

void edm::RunAuxiliary::setBeginTime ( Timestamp const &  time)
inline

Definition at line 32 of file RunAuxiliary.h.

References beginTime_, edm::Timestamp::invalidTimestamp(), and protons_cff::time.

32  {
34  beginTime_ = time;
35  }
static Timestamp invalidTimestamp()
Definition: Timestamp.h:82
Timestamp beginTime_
Definition: RunAuxiliary.h:51

◆ setEndTime()

void edm::RunAuxiliary::setEndTime ( Timestamp const &  time)
inline

Definition at line 36 of file RunAuxiliary.h.

References endTime_, edm::Timestamp::invalidTimestamp(), and protons_cff::time.

36  {
38  endTime_ = time;
39  }
static Timestamp invalidTimestamp()
Definition: Timestamp.h:82
Timestamp endTime_
Definition: RunAuxiliary.h:52

◆ setProcessHistoryID()

void edm::RunAuxiliary::setProcessHistoryID ( ProcessHistoryID const &  phid)
inline

Definition at line 26 of file RunAuxiliary.h.

References processHistoryID_.

Referenced by edm::RootOutputFile::writeRun().

26 { processHistoryID_ = phid; }
ProcessHistoryID processHistoryID_
Definition: RunAuxiliary.h:46

◆ write()

void edm::RunAuxiliary::write ( std::ostream &  os) const

Definition at line 10 of file RunAuxiliary.cc.

References id_, and processHistoryID_.

Referenced by pkg.AbstractPkg::generate().

10  {
11  os << "Process History ID = " << processHistoryID_ << std::endl;
12  os << id_ << std::endl;
13  }
ProcessHistoryID processHistoryID_
Definition: RunAuxiliary.h:46

Friends And Related Function Documentation

◆ conversion

void conversion ( RunAux const &  from,
RunAuxiliary to 
)
friend

Definition at line 11 of file RunAux.cc.

11  {
12  to.processHistoryID_ = from.processHistoryID_;
13  to.id_ = RunID(from.id_);
14  to.beginTime_ = to.endTime_ = Timestamp::invalidTimestamp();
15  }
static Timestamp invalidTimestamp()
Definition: Timestamp.h:82

Member Data Documentation

◆ beginTime_

Timestamp edm::RunAuxiliary::beginTime_
private

Definition at line 51 of file RunAuxiliary.h.

Referenced by beginTime(), mergeNewTimestampsIntoThis_(), and setBeginTime().

◆ endTime_

Timestamp edm::RunAuxiliary::endTime_
private

Definition at line 52 of file RunAuxiliary.h.

Referenced by endTime(), mergeNewTimestampsIntoThis_(), and setEndTime().

◆ id_

RunID edm::RunAuxiliary::id_
private

Definition at line 49 of file RunAuxiliary.h.

Referenced by id(), mergeAuxiliary(), run(), and write().

◆ processHistoryID_

ProcessHistoryID edm::RunAuxiliary::processHistoryID_
private

Definition at line 46 of file RunAuxiliary.h.

Referenced by processHistoryID(), setProcessHistoryID(), and write().