BOSS 6.6.4.p01
BESIII Offline Software System
Loading...
Searching...
No Matches
BesMucHit.hh
Go to the documentation of this file.
1//---------------------------------------------------------------------------//
2// BOOST --- BESIII Object_Oriented Simulation Tool //
3//---------------------------------------------------------------------------//
4//Description: Hit in MUC
5//Author: Youzy Peking University mail: [email protected]
6//Created: Nov, 2003
7//Modified:
8//Comment:
9//---------------------------------------------------------------------------//
10
11//
12// $Id: BesMucHit.hh,v 1.3 2009/08/25 13:33:54 xieyg Exp $
13// GEANT4 tag $Name: MucSim-00-01-03 $
14
15#ifndef BesMucHit_h
16#define BesMucHit_h 1
17
18#include "G4VHit.hh"
19#include "G4THitsCollection.hh"
20#include "G4Allocator.hh"
21#include "G4ThreeVector.hh"
22#include "G4VPhysicalVolume.hh"
23#include "G4LogicalVolume.hh"
24//#include "BesDetectorConstruction.hh"
25
26class BesMucHit : public G4VHit
27{
28public:
29 BesMucHit();
30 BesMucHit(int prt, int seg, int lay, int str, int trId, int trIndex);
31 //BesMucHit(BesDetectorConstruction*);
32 ~BesMucHit();
33 BesMucHit(const BesMucHit&);
34 const BesMucHit& operator=(const BesMucHit&);
35 int operator==(const BesMucHit&) const;
36
37 inline void* operator new(size_t);
38 inline void operator delete(void*);
39
40 void Draw();
41 void Print();
42
43public:
44
45 void SetTrackID(G4int track) { m_TrackID = track; };
46 void SetTrackIndex(G4int index) { m_TrackIndex = index;};
47 void SetPDGCode(G4int pdg) { m_PDGCode = pdg; };
48 void SetEdep(G4double de) { m_Edep = de; };
49 void SetEnergy(G4double energy) { m_Energy = energy; };
50 void SetTime(G4double t) { m_Time = t; };
51 void SetPos(G4ThreeVector xyz) { m_Pos = xyz; };
52 void SetPosLocal(G4ThreeVector xyzLocal) { m_PosLocal = xyzLocal; };
53 void SetDir(G4ThreeVector dir) { m_Dir = dir; };
54 void SetMomentum(G4ThreeVector momentum) { m_Momentum = momentum; };
55 void SetVolume(G4VPhysicalVolume* pv);
56 void SetPart(G4int part) { m_Part = part; };
57 void SetSeg(G4int seg) { m_Seg = seg; };
58 void SetGap(G4int gap) { m_Gap = gap; };
59 void SetStrip(G4int strip) { m_Strip = strip; };
60
61
62 G4int GetTrackID() { return m_TrackID; };
63 G4int GetTrackIndex() { return m_TrackIndex;};
64 G4int GetPDGCode() { return m_PDGCode; };
65 G4double GetEdep() { return m_Edep; };
66 G4double GetEnergy() { return m_Energy; };
67 G4double GetTime() { return m_Time; };
68 G4ThreeVector GetPos() { return m_Pos; };
69 G4ThreeVector GetPosLocal() { return m_PosLocal; };
70 G4ThreeVector GetDir() { return m_Dir; };
71 G4ThreeVector GetMomentum() { return m_Momentum; };
72 G4VPhysicalVolume* GetVolume() { return m_Volume; };
73 G4String GetVolumeName() { return m_VolumeName; };
74 G4int GetPart() { return m_Part; };
75 G4int GetSeg() { return m_Seg; };
76 G4int GetGap() { return m_Gap; };
77 G4int GetStrip() { return m_Strip; };
78 G4int GetPanel() { return m_Panel; };
79 G4int GetGasChamber() { return m_GasChamber; };
80
81private:
82
83 G4int m_TrackID; // g4 track id
84 G4int m_TrackIndex; // MC truth id
85 G4int m_PDGCode;
86 G4double m_Edep;
87 G4double m_Energy;
88 G4double m_Time;
89 G4ThreeVector m_Pos;
90 G4ThreeVector m_PosLocal;
91 G4ThreeVector m_Dir;
92 G4ThreeVector m_Momentum;
93 G4VPhysicalVolume* m_Volume;
94 G4String m_VolumeName;
95 G4int m_Part;
96 G4int m_Seg;
97 G4int m_Gap;
98 G4int m_Strip;
99 G4int m_Panel;
100 G4int m_GasChamber;
101 // BesDetectorConstruction* detector;
102};
103
104typedef G4THitsCollection<BesMucHit> BesMucHitsCollection;
105
106extern G4Allocator<BesMucHit> BesMucHitAllocator;
107
108inline void* BesMucHit::operator new(size_t)
109{
110 void *aHit;
111 aHit = (void *) BesMucHitAllocator.MallocSingle();
112 return aHit;
113}
114
115inline void BesMucHit::operator delete(void *aHit)
116{
117 BesMucHitAllocator.FreeSingle((BesMucHit*) aHit);
118}
119
120#endif
121
122
**********INTEGER nmxhep !maximum number of particles DOUBLE PRECISION vhep INTEGER jdahep COMMON hepevt $ !serial number $ !number of particles $ !status code $ !particle ident KF $ !parent particles $ !childreen particles $ !four momentum
G4Allocator< BesMucHit > BesMucHitAllocator
Definition: BesMucHit.cc:23
G4THitsCollection< BesMucHit > BesMucHitsCollection
Definition: BesMucHit.hh:104
************Class m_ypar INTEGER m_KeyWgt INTEGER m_nphot INTEGER m_KeyGPS INTEGER m_IsBeamPolarized INTEGER m_EvtGenInterface DOUBLE PRECISION m_Emin DOUBLE PRECISION m_sphot DOUBLE PRECISION m_Xenph DOUBLE PRECISION m_q2 DOUBLE PRECISION m_PolBeam2 DOUBLE PRECISION m_xErrPb *COMMON c_KK2f $ !CMS energy average $ !Spin Polarization vector first beam $ !Spin Polarization vector second beam $ !Beam energy spread[GeV] $ !minimum hadronization energy[GeV] $ !input READ never touch them !$ !debug facility $ !maximum weight $ !inverse alfaQED $ !minimum real photon energy
Definition: KK2f.h:50
#define prt(n)
void SetPos(G4ThreeVector xyz)
Definition: BesMucHit.hh:51
G4int GetTrackIndex()
Definition: BesMucHit.hh:63
void SetGap(G4int gap)
Definition: BesMucHit.hh:58
G4ThreeVector GetPos()
Definition: BesMucHit.hh:68
G4double GetEdep()
Definition: BesMucHit.hh:65
void SetTime(G4double t)
Definition: BesMucHit.hh:50
void SetPosLocal(G4ThreeVector xyzLocal)
Definition: BesMucHit.hh:52
G4int GetSeg()
Definition: BesMucHit.hh:75
G4int GetTrackID()
Definition: BesMucHit.hh:62
void SetVolume(G4VPhysicalVolume *pv)
Definition: BesMucHit.cc:92
G4int GetPanel()
Definition: BesMucHit.hh:78
void SetPart(G4int part)
Definition: BesMucHit.hh:56
void SetDir(G4ThreeVector dir)
Definition: BesMucHit.hh:53
G4int GetStrip()
Definition: BesMucHit.hh:77
G4ThreeVector GetPosLocal()
Definition: BesMucHit.hh:69
G4int GetPDGCode()
Definition: BesMucHit.hh:64
G4int GetPart()
Definition: BesMucHit.hh:74
void SetSeg(G4int seg)
Definition: BesMucHit.hh:57
void Draw()
Definition: BesMucHit.cc:139
G4double GetEnergy()
Definition: BesMucHit.hh:66
int operator==(const BesMucHit &) const
Definition: BesMucHit.cc:87
~BesMucHit()
Definition: BesMucHit.cc:38
void SetPDGCode(G4int pdg)
Definition: BesMucHit.hh:47
void SetEnergy(G4double energy)
Definition: BesMucHit.hh:49
void Print()
Definition: BesMucHit.cc:174
const BesMucHit & operator=(const BesMucHit &)
Definition: BesMucHit.cc:64
void SetTrackID(G4int track)
Definition: BesMucHit.hh:45
G4String GetVolumeName()
Definition: BesMucHit.hh:73
void SetEdep(G4double de)
Definition: BesMucHit.hh:48
G4ThreeVector GetMomentum()
Definition: BesMucHit.hh:71
void SetStrip(G4int strip)
Definition: BesMucHit.hh:59
void SetMomentum(G4ThreeVector momentum)
Definition: BesMucHit.hh:54
void SetTrackIndex(G4int index)
Definition: BesMucHit.hh:46
G4int GetGap()
Definition: BesMucHit.hh:76
G4VPhysicalVolume * GetVolume()
Definition: BesMucHit.hh:72
G4ThreeVector GetDir()
Definition: BesMucHit.hh:70
G4double GetTime()
Definition: BesMucHit.hh:67
G4int GetGasChamber()
Definition: BesMucHit.hh:79
int t()
Definition: t.c:1