BOSS 8.0.0
BESIII Offline Software System
Loading...
Searching...
No Matches
Muc/MucRecEvent/include/MucRecEvent/MucRecHit.h
Go to the documentation of this file.
1//$id$
2//
3//$log$
4
5/*
6 * 2003/12/12 Zhengyun You Peking University
7 *
8 * 2004/09/12 Zhengyun You Peking University
9 * transplanted to Gaudi framework
10 */
11
12#ifndef MUC_REC_HIT_H
13#define MUC_REC_HIT_H
14
15#include <CLHEP/Geometry/Point3D.h>
16#include <CLHEP/Geometry/Vector3D.h>
17#include <CLHEP/Vector/ThreeVector.h>
18
19#include "EventModel/EventModel.h"
20#include "GaudiKernel/ContainedObject.h"
21#include "GaudiKernel/ObjectVector.h"
22#include "GaudiKernel/SmartRef.h"
23#include "Identifier/Identifier.h"
24#include "MucGeomSvc/IMucGeomSvc.h"
25#include "MucGeomSvc/MucGeoGap.h"
26#include "MucGeomSvc/MucGeoGeneral.h"
27#include "MucGeomSvc/MucGeoStrip.h"
28
29#ifndef ENABLE_BACKWARDS_COMPATIBILITY
30typedef HepGeom::Point3D<double> HepPoint3D;
31#endif
32#ifndef ENABLE_BACKWARDS_COMPATIBILITY
33typedef HepGeom::Vector3D<double> HepVector3D;
34#endif
35
36using namespace std;
37using namespace CLHEP;
38
39extern const CLID& CLID_MucRecHit;
40
41class MucRecHit : virtual public ContainedObject {
42public:
43 /// Constructor.
44 MucRecHit() { ; }
45
46 /// Constructor.
47 MucRecHit( const Identifier& id );
48
49 /// Constructor.
50 MucRecHit( const int part = -1, const int seg = -1, const int gap = -1,
51 const int strip = -1 );
52
53 /// Copy constructor.
54 MucRecHit( const MucRecHit& source );
55
56 /// Assignment operator.
57 MucRecHit& operator=( const MucRecHit& orig );
58
59 /// Destructor.
61
62 virtual const CLID& clID() const { return MucRecHit::classID(); }
63 static const CLID& classID() { return CLID_MucRecHit; }
64
65public:
66 /// Get soft identifier of this hit.
67 Identifier GetID() const { return m_MucID; }
68
69 /// Get Part.
70 int Part() const { return MucID::part( m_MucID ); }
71
72 /// Get Seg.
73 int Seg() const { return MucID::seg( m_MucID ); }
74
75 /// Get Gap.
76 int Gap() const { return MucID::gap( m_MucID ); }
77
78 /// Get Strip.
79 int Strip() const { return MucID::strip( m_MucID ); }
80
81 /// Get geometry data for the gap containing this hit.
82 MucGeoGap* GetGap() const { return m_pMucGeoGap; }
83
84 /// Get geometry data for the strip containing this hit.
85 MucGeoStrip* GetStrip() const { return m_pMucGeoStrip; }
86
87 /// Get Center position of the strip (global coords).
88 Hep3Vector GetCenterPos() const;
89
90 /// Get Center position uncertainty of the strip (global coords).
91 Hep3Vector GetCenterSigma() const;
92
93 void SetHitMode( int recmode ) { m_recmode = recmode; }
94
95 int GetHitMode() const { return m_recmode; }
96
97 void SetHitSeed( int seed ) { m_IsSeed = seed; }
98
99 int HitIsSeed() const { return m_IsSeed; }
100
101 void SetPadID( int padID ) { m_padID = padID; }
102 void SetIntersectX( float x ) { m_intersect_x = x; }
103 void SetIntersectY( float y ) { m_intersect_y = y; }
104 void SetIntersectZ( float z ) { m_intersect_z = z; }
105
106 int GetPadID() const { return m_padID; }
107 float GetIntersectX() const { return m_intersect_x; }
108 float GetIntersectY() const { return m_intersect_y; }
109 float GetIntersectZ() const { return m_intersect_z; }
110
111private:
112 Identifier m_MucID;
113 int m_padID; // Which pad is expected, Only used in expected hit,
114 float m_intersect_x; // intersection position of expected hit
115 float m_intersect_y;
116 float m_intersect_z;
117 MucGeoGap* m_pMucGeoGap;
118 MucGeoStrip* m_pMucGeoStrip;
119 HepPoint3D m_CenterPos; // Position of strip which was hit.
120 HepPoint3D m_CenterSigma; // Uncert. in position of strip.
121 int m_recmode; // 1: mdc ext ; 2 emc ext
122 int m_IsSeed;
123};
124
125typedef ObjectVector<MucRecHit> MucRecHitCol;
126
127#endif /* MUC_REC_HIT_H */
HepGeom::Vector3D< double > HepVector3D
HepGeom::Point3D< double > HepPoint3D
const CLID & CLID_MucRecHit
const CLID & CLID_MucRecHit
static int part(const Identifier &id)
Definition MucID.cxx:43
static int gap(const Identifier &id)
Definition MucID.cxx:63
static int seg(const Identifier &id)
Definition MucID.cxx:53
static int strip(const Identifier &id)
Definition MucID.cxx:73
MucRecHit(const Identifier &id)
Constructor.
~MucRecHit()
Destructor.
MucRecHit(const MucRecHit &source)
Copy constructor.
MucRecHit & operator=(const MucRecHit &orig)
Assignment operator.
MucGeoGap * GetGap() const
Get geometry data for the gap containing this hit.
Hep3Vector GetCenterPos() const
Get Center position of the strip (global coords).
Hep3Vector GetCenterSigma() const
Get Center position uncertainty of the strip (global coords).
MucGeoStrip * GetStrip() const
Get geometry data for the strip containing this hit.
Identifier GetID() const
Get soft identifier of this hit.
MucRecHit(const int part=-1, const int seg=-1, const int gap=-1, const int strip=-1)
Constructor.
virtual const CLID & clID() const