BOSS 7.0.2
BESIII Offline Software System
Loading...
Searching...
No Matches
InstallArea/include/EmcSim/EmcSim/BesEmcDigi.hh
Go to the documentation of this file.
1//---------------------------------------------------------------------------//
2// BOOST --- BESIII Object_Oriented Simulation Tool //
3//---------------------------------------------------------------------------//
4//Description:
5//Author: Hemiao
6//Created: Sep, 2004
7//Modified:
8//Comment:
9//---------------------------------------------------------------------------//
10// $Id: BesEmcDigi.hh
11
12#ifndef BesEmcDigi_h
13#define BesEmcDigi_h 1
14
15#include "G4VDigi.hh"
16#include "G4TDigiCollection.hh"
17#include "G4Allocator.hh"
18#include "BesEmcWaveform.hh"
19
20class BesEmcDigi : public G4VDigi
21{
22 public:
23 BesEmcDigi();
24 virtual ~BesEmcDigi();
25
26 BesEmcDigi(const BesEmcDigi&);
27 const BesEmcDigi& operator=(const BesEmcDigi&);
28
29 virtual BesEmcDigi& operator+=(const BesEmcDigi&);
30 virtual G4int operator==(const BesEmcDigi&) const;
31 inline void* operator new(size_t);
32 inline void operator delete(void*);
33
34 virtual void Draw();
35 virtual void Print();
36
37 public:
38 void MakeWaveform();
39
40 public:
41 void SetPartId(G4int id) { m_partId = id; };
42 void SetThetaNb(G4int nTheta) { m_nTheta = nTheta; };
43 void SetPhiNb(G4int nPhi) { m_nPhi = nPhi; };
44 void SetEnergy(G4double energy) { m_energy = energy; };
45 void SetTime(G4double time) { m_time = time;};
46 void SetTrackIndex(G4int index){ m_trackIndex = index; };
47 void SetWaveform(BesEmcWaveform* wave) { digiWaveform = wave; };
48
49 G4int GetPartId() {return m_partId;};
50 G4int GetThetaNb() { return m_nTheta;};
51 G4int GetPhiNb() { return m_nPhi; };
52 G4double GetEnergy() { return m_energy; };
53 G4double GetTime(){ return m_time; };
54 G4int GetTrackIndex(){ return m_trackIndex; };
55 BesEmcWaveform* GetWaveform(){ return digiWaveform; };
56
57 private:
58 BesEmcWaveform* digiWaveform;
59
60 private:
61 G4int m_partId;
62 G4int m_nTheta;
63 G4int m_nPhi;
64 G4double m_energy;
65 G4double m_time;
66 G4int m_trackIndex;
67};
68
69typedef G4TDigiCollection<BesEmcDigi> BesEmcDigitsCollection;
70
71extern G4Allocator<BesEmcDigi> BesEmcDigiAllocator;
72
73inline void* BesEmcDigi::operator new(size_t)
74{
75 void *aDigi;
76 aDigi = (void *) BesEmcDigiAllocator.MallocSingle();
77 return aDigi;
78}
79
80inline void BesEmcDigi::operator delete(void *aDigi)
81{
82 BesEmcDigiAllocator.FreeSingle((BesEmcDigi*) aDigi);
83}
84
85#endif
86
Double_t time
G4TDigiCollection< BesEmcDigi > BesEmcDigitsCollection
G4Allocator< BesEmcDigi > BesEmcDigiAllocator
Definition: BesEmcDigi.cc:14
************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
virtual G4int operator==(const BesEmcDigi &) const
Definition: BesEmcDigi.cc:67
virtual void Print()
Definition: BesEmcDigi.cc:78
virtual void Draw()
Definition: BesEmcDigi.cc:73
void SetWaveform(BesEmcWaveform *wave)
virtual ~BesEmcDigi()
Definition: BesEmcDigi.cc:26
virtual BesEmcDigi & operator+=(const BesEmcDigi &)
Definition: BesEmcDigi.cc:54
const BesEmcDigi & operator=(const BesEmcDigi &)
Definition: BesEmcDigi.cc:43
void MakeWaveform()
Definition: BesEmcDigi.cc:82