#include <SimDataFormats/CrossingFrame/interface/CrossingFramePlaybackInfo.h>
Public Member Functions | |
CrossingFramePlaybackInfo (int minBunch, int maxBunch, unsigned int maxNbSources) | |
CrossingFramePlaybackInfo () | |
void | getEventStartInfo (std::vector< edm::EventID > &ids, std::vector< int > &fileNrs, std::vector< unsigned int > &nrEvents, const unsigned int s) const |
int | getNrEvents (const unsigned int s, const int bcr) const |
edm::EventID | getStartEventId (const unsigned int s, const int bcr) const |
int | getStartFileNr (const unsigned int s, const int bcr) const |
void | setEventStartInfo (std::vector< edm::EventID > &id, std::vector< int > &fileNr, std::vector< unsigned int > &nrEvents, const unsigned int s) |
void | setNrEvents (const unsigned int nr, const unsigned int s, const int bcr) |
void | setStartEventId (const edm::EventID &id, const unsigned int s, const int bcr) |
void | setStartFileNr (const unsigned int nr, const unsigned int s, const int bcr) |
~CrossingFramePlaybackInfo () | |
Private Attributes | |
std::vector< std::vector < edm::EventID > > | idFirstPileup_ |
unsigned int | maxNbSources_ |
int | minBunch_ |
int | nBcrossings_ |
std::vector< std::vector < unsigned int > > | nrEvents_ |
std::vector< std::vector< int > > | pileupFileNr_ |
Definition at line 20 of file CrossingFramePlaybackInfo.h.
CrossingFramePlaybackInfo::CrossingFramePlaybackInfo | ( | ) | [inline] |
CrossingFramePlaybackInfo::CrossingFramePlaybackInfo | ( | int | minBunch, | |
int | maxBunch, | |||
unsigned int | maxNbSources | |||
) |
Definition at line 3 of file CrossingFramePlaybackInfo.cc.
References i, idFirstPileup_, j, maxNbSources_, nBcrossings_, nrEvents_, and pileupFileNr_.
00003 :maxNbSources_(maxNbSources),minBunch_(minBunch) 00004 { 00005 //initialise data structures 00006 nBcrossings_=maxBunch-minBunch+1; 00007 pileupFileNr_.resize(maxNbSources_); 00008 idFirstPileup_.resize(maxNbSources_); 00009 nrEvents_.resize(maxNbSources_); 00010 for (unsigned int i=0;i<maxNbSources_;++i) { 00011 pileupFileNr_[i].resize(nBcrossings_); 00012 idFirstPileup_[i].resize(nBcrossings_); 00013 nrEvents_[i].resize(nBcrossings_); 00014 for (int j=0;j<nBcrossings_;++j) { 00015 (pileupFileNr_[i])[j]=-1; 00016 (idFirstPileup_[i])[j]=edm::EventID(0,0); 00017 (nrEvents_[i])[j]=0; 00018 } 00019 } 00020 }
CrossingFramePlaybackInfo::~CrossingFramePlaybackInfo | ( | ) | [inline] |
void CrossingFramePlaybackInfo::getEventStartInfo | ( | std::vector< edm::EventID > & | ids, | |
std::vector< int > & | fileNrs, | |||
std::vector< unsigned int > & | nrEvents, | |||
const unsigned int | s | |||
) | const [inline] |
Definition at line 36 of file CrossingFramePlaybackInfo.h.
References idFirstPileup_, nrEvents_, and pileupFileNr_.
00036 { 00037 ids=idFirstPileup_[s]; 00038 fileNrs= pileupFileNr_[s]; 00039 nrEvents=nrEvents_[s]; 00040 }
edm::EventID CrossingFramePlaybackInfo::getStartEventId | ( | const unsigned int | s, | |
const int | bcr | |||
) | const [inline] |
Definition at line 33 of file CrossingFramePlaybackInfo.h.
References idFirstPileup_, and minBunch_.
00033 {return (idFirstPileup_[s])[bcr-minBunch_];}
int CrossingFramePlaybackInfo::getStartFileNr | ( | const unsigned int | s, | |
const int | bcr | |||
) | const [inline] |
Definition at line 32 of file CrossingFramePlaybackInfo.h.
References minBunch_, and pileupFileNr_.
00032 {return (pileupFileNr_[s])[bcr-minBunch_];}
void CrossingFramePlaybackInfo::setEventStartInfo | ( | std::vector< edm::EventID > & | id, | |
std::vector< int > & | fileNr, | |||
std::vector< unsigned int > & | nrEvents, | |||
const unsigned int | s | |||
) |
Definition at line 22 of file CrossingFramePlaybackInfo.cc.
References idFirstPileup_, nrEvents_, and pileupFileNr_.
00023 { 00024 idFirstPileup_[s]=id; 00025 pileupFileNr_[s]=fileNr; 00026 nrEvents_[s]=nrEvents; 00027 }
void CrossingFramePlaybackInfo::setStartEventId | ( | const edm::EventID & | id, | |
const unsigned int | s, | |||
const int | bcr | |||
) | [inline] |
Definition at line 45 of file CrossingFramePlaybackInfo.h.
References idFirstPileup_, and minBunch_.
00045 {idFirstPileup_[s][bcr-minBunch_]=id;}
void CrossingFramePlaybackInfo::setStartFileNr | ( | const unsigned int | nr, | |
const unsigned int | s, | |||
const int | bcr | |||
) | [inline] |
Definition at line 44 of file CrossingFramePlaybackInfo.h.
References minBunch_, and pileupFileNr_.
00044 {pileupFileNr_[s][bcr-minBunch_]=nr;}
std::vector<std::vector<edm::EventID> > CrossingFramePlaybackInfo::idFirstPileup_ [private] |
Definition at line 53 of file CrossingFramePlaybackInfo.h.
Referenced by CrossingFramePlaybackInfo(), getEventStartInfo(), getStartEventId(), setEventStartInfo(), and setStartEventId().
unsigned int CrossingFramePlaybackInfo::maxNbSources_ [private] |
Definition at line 52 of file CrossingFramePlaybackInfo.h.
Referenced by CrossingFramePlaybackInfo().
int CrossingFramePlaybackInfo::minBunch_ [private] |
Definition at line 58 of file CrossingFramePlaybackInfo.h.
Referenced by getNrEvents(), getStartEventId(), getStartFileNr(), setNrEvents(), setStartEventId(), and setStartFileNr().
int CrossingFramePlaybackInfo::nBcrossings_ [private] |
Definition at line 57 of file CrossingFramePlaybackInfo.h.
Referenced by CrossingFramePlaybackInfo().
std::vector<std::vector<unsigned int> > CrossingFramePlaybackInfo::nrEvents_ [private] |
Definition at line 55 of file CrossingFramePlaybackInfo.h.
Referenced by CrossingFramePlaybackInfo(), getEventStartInfo(), getNrEvents(), setEventStartInfo(), and setNrEvents().
std::vector<std::vector<int> > CrossingFramePlaybackInfo::pileupFileNr_ [private] |
Definition at line 54 of file CrossingFramePlaybackInfo.h.
Referenced by CrossingFramePlaybackInfo(), getEventStartInfo(), getStartFileNr(), setEventStartInfo(), and setStartFileNr().