Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ struct InteractionRecord {

bool operator==(const InteractionRecord& other) const
{
return (orbit == other.orbit) && (bc == other.bc);
return (bc == other.bc) && (orbit == other.orbit);
}

int differenceInBC(const InteractionRecord& other) const
Expand All @@ -81,6 +81,22 @@ struct InteractionRecord {
return diffBC;
}

int64_t toLong() const
{
// return as single long number
return (int64_t(orbit) * o2::constants::lhc::LHCMaxBunches) + bc;
}

bool operator>(const InteractionRecord& other) const
{
return (orbit == other.orbit) ? (bc > other.bc) : (orbit > other.orbit);
}

bool operator<(const InteractionRecord& other) const
{
return (orbit == other.orbit) ? (bc < other.bc) : (orbit < other.orbit);
}

void print() const;

ClassDefNV(InteractionRecord, 3);
Expand Down