BOSS 8.0.0
BESIII Offline Software System
Loading...
Searching...
No Matches
EmcMcHit.cxx
Go to the documentation of this file.
1#include "McTruth/EmcMcHit.h"
2
3Event::EmcMcHit::EmcMcHit( const Identifier& id, unsigned int trackIndex, double xPosition,
4 double yPosition, double zPosition, double px, double py, double pz,
5 double depositEnergy )
6 : m_id( id )
7 , m_trackIndex( trackIndex )
8 , m_hitEmc( 0 )
9 , m_PDGCode( 0 )
10 , m_PDGCharge( 0 )
11 , m_time( 0 )
12 , m_xPosition( xPosition )
13 , m_yPosition( yPosition )
14 , m_zPosition( zPosition )
15 , m_px( px )
16 , m_py( py )
17 , m_pz( pz )
18 , m_depositEnergy( depositEnergy ) {
19 m_hitMap.clear();
20}
21
22// Get associated id
23Identifier Event::EmcMcHit::identify() const { return m_id; }
24
25// Get the associated track id
26unsigned int Event::EmcMcHit::getTrackIndex() const { return m_trackIndex; }
27
28// Whether hit Emc
29int Event::EmcMcHit::getHitEmc() const { return m_hitEmc; }
30
31// Get PDG code
32int Event::EmcMcHit::getPDGCode() const { return m_PDGCode; }
33
34// Get PDG charge
35double Event::EmcMcHit::getPDGCharge() const { return m_PDGCharge; }
36
37// Get time
38double Event::EmcMcHit::getTime() const { return m_time; }
39
40// Get the position x
41double Event::EmcMcHit::getPositionX() const { return m_xPosition; }
42
43// Get the position y
44double Event::EmcMcHit::getPositionY() const { return m_yPosition; }
45
46// Get the position z
47double Event::EmcMcHit::getPositionZ() const { return m_zPosition; }
48
49// Get momentum Px
50double Event::EmcMcHit::getPx() const { return m_px; }
51
52// Get momentum Py
53double Event::EmcMcHit::getPy() const { return m_py; }
54
55// Get momentum Pz
56double Event::EmcMcHit::getPz() const { return m_pz; }
57
58// Get the total deposited energy
59double Event::EmcMcHit::getDepositEnergy() const { return m_depositEnergy; }
60
61std::map<Identifier, double>::const_iterator Event::EmcMcHit::begin() const {
62 return m_hitMap.begin();
63}
64
65std::map<Identifier, double>::const_iterator Event::EmcMcHit::end() const {
66 return m_hitMap.end();
67}
68
69std::map<Identifier, double>::const_iterator Event::EmcMcHit::find( Identifier& id ) const {
70 return m_hitMap.find( id );
71}
72
73unsigned int Event::EmcMcHit::size() const { return m_hitMap.size(); }
74
75std::map<Identifier, double> Event::EmcMcHit::getHitMap() const { return m_hitMap; }
Identifier identify() const
Definition EmcMcHit.cxx:23
std::map< Identifier, double > getHitMap() const
Definition EmcMcHit.cxx:75
double getPositionZ() const
Definition EmcMcHit.cxx:47
unsigned int size() const
Definition EmcMcHit.cxx:73
int getPDGCode() const
Definition EmcMcHit.cxx:32
int getHitEmc() const
Definition EmcMcHit.cxx:29
std::map< Identifier, double >::const_iterator end() const
Definition EmcMcHit.cxx:65
double getTime() const
Definition EmcMcHit.cxx:38
double getPx() const
Definition EmcMcHit.cxx:50
double getPDGCharge() const
Definition EmcMcHit.cxx:35
double getDepositEnergy() const
Definition EmcMcHit.cxx:59
double getPy() const
Definition EmcMcHit.cxx:53
std::map< Identifier, double >::const_iterator find(Identifier &) const
Definition EmcMcHit.cxx:69
double getPositionY() const
Definition EmcMcHit.cxx:44
double getPz() const
Definition EmcMcHit.cxx:56
std::map< Identifier, double >::const_iterator begin() const
Definition EmcMcHit.cxx:61
unsigned int getTrackIndex() const
Definition EmcMcHit.cxx:26
double getPositionX() const
Definition EmcMcHit.cxx:41