ATLAS Offline Software
RPCdigit.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 #ifndef RPCDIGIT_H
6 #define RPCDIGIT_H
7 
8 #include <list>
9 
12 //#include "RPCgeometry/RPCGeometry.h"
14 
16 {
17  private:
19 
20  float m_x;
21  float m_y;
22  float m_z;
23 
24  float m_time;
25 
28 
29  std::list<unsigned int> m_codes;
30 
31  public:
32  RPCdigit();
33  RPCdigit(const std::string&,int,unsigned int, float vec[4]);
34 
35  /*
36  RPCdigit(std::string,int,unsigned int, float vec[4],
37  const RPCGeometry* rpcgeo);
38  RPCdigit(std::string,int,std::list<unsigned int>,float,
39  const RPCGeometry* rpcgeo);
40  */
41  RPCdigit(const RPCdigit&);
42  virtual ~RPCdigit() {}
43 
45 
46  bool operator==(const RPCdigit&) const;
47 
48  const RPCdecoder& decoding(void) const {return m_coding;}
49  //const RPCGeometry* rpcgeo(void) const {return m_rpcgeo;}
50  const std::list<unsigned int>& codes(void) const {return m_codes;}
51 
52  float time (void) const {return m_time;}
53  float x(void) const {return m_x;}
54  float y(void) const {return m_y;}
55  float z(void) const {return m_z;}
56 
57  void xyz(float vec[3]) const;
58  bool radius(float&) const;
59  bool theta(float&) const;
60  bool eta(float&) const;
61  bool phi(float&) const;
62 
63  bool station_radius(float&) const;
64  bool station_eta(float&) const;
65  bool station_phi(float&) const;
66 
67 
68  //bool set_to_chamber(const int rpc_index);
69 
70  virtual int particle_code(void) const {return 0;}
71  virtual int process_type(void) const {return 0;}
72  virtual int track_number(void) const {return 0;}
73 
74  virtual const MuonSimuTrack* muon(void) const {return 0;}
75 
76  void Print(std::ostream&,bool) const;
77 };
78 
79 
80 inline bool
82 {
84  {
86  return true;
87  }
88  return false;
89 }
90 
91 
92 inline bool
94 {
95  if(m_station_phi >= 0.)
96  {
98  return true;
99  }
100  return false;
101 }
102 
103 
104 
105 
106 template <class X> X& operator<<(X& stream,const RPCdigit& data)
107 {
108  std::ostringstream display;
109  data.Print(display,false);
110  stream << display.str();
111  return stream;
112 }
113 
114 #endif
RPCdigit::track_number
virtual int track_number(void) const
Definition: RPCdigit.h:72
RPCdigit::station_radius
bool station_radius(float &) const
Definition: RPCdigit.h:81
RPCdigit::eta
bool eta(float &) const
Definition: RPCdigit.cxx:205
RPCdecoder
Definition: RPCdecoder.h:13
RPCdigit::operator=
RPCdigit operator=(const RPCdigit &)
Definition: RPCdigit.cxx:142
data
char data[hepevt_bytes_allocation_ATLAS]
Definition: HepEvt.cxx:11
MuonSimuTrack.h
phi
Scalar phi() const
phi method
Definition: AmgMatrixBasePlugin.h:67
RPCdigit::m_z
float m_z
Definition: RPCdigit.h:22
RPCdigit::operator==
bool operator==(const RPCdigit &) const
Definition: RPCdigit.cxx:169
RPCdigit::time
float time(void) const
Definition: RPCdigit.h:52
RPCdigit::m_codes
std::list< unsigned int > m_codes
Definition: RPCdigit.h:29
RPCdigit::m_y
float m_y
Definition: RPCdigit.h:21
vec
std::vector< size_t > vec
Definition: CombinationsGeneratorTest.cxx:12
RPCdigit::phi
bool phi(float &) const
Definition: RPCdigit.cxx:217
AthenaPoolTestWrite.stream
string stream
Definition: AthenaPoolTestWrite.py:12
Monitored::X
@ X
Definition: HistogramFillerUtils.h:24
RPCdigit::muon
virtual const MuonSimuTrack * muon(void) const
Definition: RPCdigit.h:74
RPCdigit::m_time
float m_time
Definition: RPCdigit.h:24
RPCdigit::Print
void Print(std::ostream &, bool) const
Definition: RPCdigit.cxx:238
RPCdigit::station_phi
bool station_phi(float &) const
Definition: RPCdigit.h:93
RPCdecoder.h
RPCdigit::m_coding
RPCdecoder m_coding
Definition: RPCdigit.h:18
RPCdigit::process_type
virtual int process_type(void) const
Definition: RPCdigit.h:71
RPCdigit::radius
bool radius(float &) const
Definition: RPCdigit.cxx:182
pyroot.display
display
Definition: pyroot.py:44
RPCdigit::theta
bool theta(float &) const
Definition: RPCdigit.cxx:193
RPCtrigDataObject
Definition: RPCtrigDataObject.h:15
RPCdigit::y
float y(void) const
Definition: RPCdigit.h:54
RPCdigit
Definition: RPCdigit.h:16
operator<<
X & operator<<(X &stream, const RPCdigit &data)
Definition: RPCdigit.h:106
RPCdigit::RPCdigit
RPCdigit()
Definition: RPCdigit.cxx:12
RPCtrigDataObject.h
RPCdigit::m_x
float m_x
Definition: RPCdigit.h:20
RPCdigit::m_station_radius
float m_station_radius
Definition: RPCdigit.h:26
RPCdigit::m_station_phi
float m_station_phi
Definition: RPCdigit.h:27
RPCdigit::decoding
const RPCdecoder & decoding(void) const
Definition: RPCdigit.h:48
RPCdigit::x
float x(void) const
Definition: RPCdigit.h:53
RPCdigit::z
float z(void) const
Definition: RPCdigit.h:55
RPCdigit::codes
const std::list< unsigned int > & codes(void) const
Definition: RPCdigit.h:50
RPCdigit::particle_code
virtual int particle_code(void) const
Definition: RPCdigit.h:70
RPCdigit::~RPCdigit
virtual ~RPCdigit()
Definition: RPCdigit.h:42
python.SystemOfUnits.rad
int rad
Definition: SystemOfUnits.py:111
MuonSimuTrack
Definition: MuonSimuTrack.h:56
RPCdigit::station_eta
bool station_eta(float &) const
Definition: RPCdigit.cxx:227
RPCdigit::xyz
void xyz(float vec[3]) const
Definition: RPCdigit.cxx:175