17#ifndef ALICEO2_MCH_ROFRECORD_H
18#define ALICEO2_MCH_ROFRECORD_H
42 ROFRecord(
const BCData&
bc,
int firstIdx,
int nEntries) : mBCData(
bc), mDataRef(firstIdx, nEntries) {}
43 ROFRecord(
const BCData&
bc,
int firstIdx,
int nEntries,
int bcWidth) : mBCData(
bc), mDataRef(firstIdx, nEntries), mBCWidth(bcWidth) {}
52 std::pair<Time, bool>
getTimeMUS(
const BCData& startIR, uint32_t nOrbits = 128,
bool printError =
false)
const;
59 int getLastIdx()
const {
return mDataRef.getFirstEntry() + mDataRef.getEntries() - 1; }
61 void setDataRef(
int firstIdx,
int nEntries) { mDataRef.set(firstIdx, nEntries); }
68 return mBCData ==
other.mBCData &&
69 mDataRef ==
other.mDataRef &&
70 mBCWidth ==
other.mBCWidth;
75 if (mBCData ==
other.mBCData) {
76 if (mBCWidth ==
other.mBCWidth) {
77 return mDataRef.getFirstEntry() <
other.mDataRef.getFirstEntry();
79 return mBCWidth <
other.mBCWidth;
82 return mBCData <
other.mBCData;
Class to refer to the 1st entry and N elements of some group in the continuous container.
ROFRecord(const BCData &bc, int firstIdx, int nEntries)
void setBCData(const BCData &bc)
set the interaction record
int getLastIdx() const
get the index of the last associated object
int getNEntries() const
get the number of associated objects
bool operator!=(const ROFRecord &other) const
const BCData & getBCData() const
get the interaction record
std::pair< Time, bool > getTimeMUS(const BCData &startIR, uint32_t nOrbits=128, bool printError=false) const
ROFRecord(const BCData &bc, int firstIdx, int nEntries, int bcWidth)
bool operator<(const ROFRecord &other) const
BCData & getBCData()
get the interaction record
int getFirstIdx() const
get the index of the first associated object
int getBCWidth() const
get the time span by this ROF, in BC unit
bool operator==(const ROFRecord &other) const
void setDataRef(int firstIdx, int nEntries)
set the number of associated objects and the index of the first one
a couple of static helper functions to create timestamp values for CCDB queries or override obsolete ...
VectorOfTObjectPtrs other