ATLAS Offline Software
FCS_StepInfo.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2022 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 #ifndef ISF_FASTCALOSIMEVENT_ISF_FCS_STEPINFO_H
6 #define ISF_FASTCALOSIMEVENT_ISF_FCS_STEPINFO_H
7 
8 // STL includes
9 #include <iostream>
10 #include <vector>
11 #include <string>
12 
13 // CLHEP include for Hep3Vector
14 #include "CLHEP/Vector/ThreeVector.h"
15 
16 // include for Hit
17 // #include "LArSimEvent/LArHit.h"
18 #include "TileSimEvent/TileHit.h"
19 
21 
22 class MsgStream;
23 
24 // Namespace for the G4 step related classes
26 
43 using namespace ISF_FCS;
44 
45 class FCS_StepInfo : public TileHit, public MLogging {
46 
47 public:
49  FCS_StepInfo() : m_pos(), m_valid(false), m_detector(-1) {}
50 
51  FCS_StepInfo(CLHEP::Hep3Vector l_vec, Identifier l_cell, double l_energy,
52  double l_time, bool l_valid, int l_detector)
53  : TileHit(l_cell, l_energy, l_time), m_pos(l_vec), m_valid(l_valid),
54  m_detector(l_detector) {}
55 
56  // FCS_StepInfo(const FCS_StepInfo& first, const FCS_StepInfo& second);
57 
58  /* access functions */
59 
61  inline void setP(const CLHEP::Hep3Vector &p) { m_pos = p; }
63  inline void setX(const double x) { return m_pos.setX(x); }
65  inline void setY(const double y) { return m_pos.setY(y); }
67  inline void setZ(const double z) { return m_pos.setZ(z); }
69  // inline void setE(const double t) { m_energy = t; }
71  // inline void setTime(const double t) { m_time = t; }
73  inline void setValid(const bool flag) { m_valid = flag; }
75  // inline void setIdentifier(const Identifier id) { m_ID = id; }
76 
77  inline void setDetector(const int det) { m_detector = det; }
79  inline CLHEP::Hep3Vector position() const { return m_pos; }
81  inline double x() const { return m_pos.x(); }
83  inline double y() const { return m_pos.y(); }
85  inline double z() const { return m_pos.z(); }
87  // inline double dep() const { return m_energy; }
89  // inline double time() const { return time(); }
91  inline bool valid() const { return m_valid; }
92 
93  inline int detector() const { return m_detector; }
94 
95  /* helper functions */
96 
98  double diff2(const FCS_StepInfo &other) const;
99 
101  FCS_StepInfo &operator+=(const FCS_StepInfo &other);
102 
103 private:
104  // data members
105  CLHEP::Hep3Vector m_pos;
106  bool m_valid;
108 };
109 
110 } // namespace ISF_FCS_Parametrization
111 
112 #endif
ISF_FCS::MLogging
Cut down AthMessaging.
Definition: MLogging.h:176
python.PerfMonSerializer.p
def p
Definition: PerfMonSerializer.py:743
ISF_FCS_Parametrization::FCS_StepInfo::setZ
void setZ(const double z)
set z position
Definition: FCS_StepInfo.h:67
ISF_FCS_Parametrization::FCS_StepInfo::FCS_StepInfo
FCS_StepInfo(CLHEP::Hep3Vector l_vec, Identifier l_cell, double l_energy, double l_time, bool l_valid, int l_detector)
Definition: FCS_StepInfo.h:51
x
#define x
ISF_FCS_Parametrization::FCS_StepInfo::z
double z() const
return z position
Definition: FCS_StepInfo.h:85
ISF_FCS
Definition: MLogging.h:66
z
#define z
ISF_FCS_Parametrization::FCS_StepInfo::m_detector
int m_detector
dictionary value in which detector the hit is
Definition: FCS_StepInfo.h:107
ISF_FCS_Parametrization::FCS_StepInfo::valid
bool valid() const
return deposited energy
Definition: FCS_StepInfo.h:91
WritePulseShapeToCool.det
det
Definition: WritePulseShapeToCool.py:204
master.flag
bool flag
Definition: master.py:29
ISF_FCS_Parametrization::FCS_StepInfo::setP
void setP(const CLHEP::Hep3Vector &p)
set position
Definition: FCS_StepInfo.h:61
ISF_FCS_Parametrization::FCS_StepInfo::setX
void setX(const double x)
set x position
Definition: FCS_StepInfo.h:63
ISF_FCS_Parametrization::FCS_StepInfo::setValid
void setValid(const bool flag)
set depoisted energy
Definition: FCS_StepInfo.h:73
ISF_FCS_Parametrization::FCS_StepInfo::position
CLHEP::Hep3Vector position() const
return spacial position
Definition: FCS_StepInfo.h:79
TileHit.h
TileHit
Definition: TileSimEvent/TileSimEvent/TileHit.h:30
ISF_FCS_Parametrization::FCS_StepInfo
Definition: FCS_StepInfo.h:45
ISF_FCS_Parametrization::FCS_StepInfo::detector
int detector() const
Definition: FCS_StepInfo.h:93
InDetDD::other
@ other
Definition: InDetDD_Defs.h:16
y
#define y
ISF_FCS_Parametrization::FCS_StepInfo::setDetector
void setDetector(const int det)
set identifier
Definition: FCS_StepInfo.h:77
ISF_FCS_Parametrization::FCS_StepInfo::m_valid
bool m_valid
flag, if hit is valid (if valid calculator?)
Definition: FCS_StepInfo.h:106
ISF_FCS_Parametrization::FCS_StepInfo::x
double x() const
return x position
Definition: FCS_StepInfo.h:81
ISF_FCS_Parametrization::FCS_StepInfo::setY
void setY(const double y)
set y position
Definition: FCS_StepInfo.h:65
ISF_FCS_Parametrization::FCS_StepInfo::y
double y() const
return y position
Definition: FCS_StepInfo.h:83
MLogging.h
ISF_FCS_Parametrization::FCS_StepInfo::m_pos
CLHEP::Hep3Vector m_pos
spatial position
Definition: FCS_StepInfo.h:105
ISF_FCS_Parametrization
Definition: FCS_StepInfo.h:25
ISF_FCS_Parametrization::FCS_StepInfo::FCS_StepInfo
FCS_StepInfo()
empty default constructor
Definition: FCS_StepInfo.h:49