ATLAS Offline Software
Loading...
Searching...
No Matches
RpcDigitCuts.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2026 CERN for the benefit of the ATLAS collaboration
3*/
4
5#ifndef VP1_RPCDIGITCUTS_H
6#define VP1_RPCDIGITCUTS_H
7
9#include <cmath>
10
12 bool showEta = true;
13 bool showPhi = true;
14 bool showPrimarySide = true;
15 bool showOppositeSide = true;
16 bool keepMissingToT = true;
19
20 // Times are in ns; a negative ToT denotes an absent measurement.
21 bool accepts(bool phi, double time, double tot, bool oppositeSide) const
22 {
23 if ((phi ? !showPhi : !showEta) ||
24 (oppositeSide ? !showOppositeSide : !showPrimarySide))
25 return false;
26 if (!std::isfinite(time) || !std::isfinite(tot) ||
27 timeRange.isEmpty() || totRange.isEmpty() || !timeRange.contains(time))
28 return false;
29 return tot < 0 ? keepMissingToT : totRange.contains(tot);
30 }
31};
32
33#endif
Scalar phi() const
phi method
static double inf()
Definition VP1Interval.h:25
VP1Interval totRange
VP1Interval timeRange
bool accepts(bool phi, double time, double tot, bool oppositeSide) const
bool showPrimarySide
bool keepMissingToT
bool showOppositeSide