DD4hep  1.30.0
Detector Description Toolkit for High Energy Physics
DDG4Dict.h
Go to the documentation of this file.
1 //==========================================================================
2 // AIDA Detector description implementation
3 //--------------------------------------------------------------------------
4 // Copyright (C) Organisation europeenne pour la Recherche nucleaire (CERN)
5 // All rights reserved.
6 //
7 // For the licensing terms see $DD4hepINSTALL/LICENSE.
8 // For the list of contributors see $DD4hepINSTALL/doc/CREDITS.
9 //
10 // Author : M.Frank
11 //
12 //==========================================================================
13 //
14 // Define the ROOT dictionaries for all data classes to be saved
15 // which are created by the DDG4 examples.
16 //
17 //====================================================================
18 #ifndef DDG4_DDG4DICT_H
19 #define DDG4_DDG4DICT_H
20 
21 #if defined(__GNUC__)
22 #pragma GCC diagnostic ignored "-Wdeprecated-declarations"
23 #pragma GCC diagnostic ignored "-Wdeprecated"
24 #pragma GCC diagnostic ignored "-Wunused"
25 #pragma GCC diagnostic ignored "-Woverlength-strings"
26 
27 #elif defined(__llvm__) || defined(__APPLE__)
28 
29 #pragma clang diagnostic ignored "-Wdefaulted-function-deleted"
30 #pragma clang diagnostic ignored "-Wdeprecated-declarations"
31 #pragma clang diagnostic ignored "-Wdeprecated"
32 #pragma clang diagnostic ignored "-Wunused"
33 #pragma clang diagnostic ignored "-Woverlength-strings"
34 #endif
35 
36 // FRamework include files
37 #include <DD4hep/Memory.h>
38 #include <DDG4/Geant4Data.h>
39 #include <DDG4/Geant4Particle.h>
40 
41 namespace dd4hep {
42  namespace DDSegmentation { }
43  namespace detail { }
44  namespace sim { }
45 }
46 
47 namespace { class DDG4Dict {}; }
48 
49 // CINT configuration
50 #if defined(__CINT__) || defined(__MAKECINT__) || defined(__CLING__) || defined(__ROOTCLING__)
51 #pragma link off all globals;
52 #pragma link off all classes;
53 #pragma link off all functions;
54 
56 #pragma link C++ namespace dd4hep;
57 #pragma link C++ namespace dd4hep::sim;
58 #pragma link C++ namespace dd4hep::detail;
59 
61 #pragma link C++ class dd4hep::sim::SimpleRun+;
62 #pragma link C++ class dd4hep::sim::SimpleEvent+;
63 #pragma link C++ class dd4hep::sim::DataExtension+;
64 
66 #pragma link C++ class dd4hep::sim::ParticleExtension+;
67 
68 #pragma link C++ class dd4hep::sim::Geant4Particle+;
69 #pragma link C++ class std::vector<dd4hep::sim::Geant4Particle*>+;
70 #pragma link C++ class std::map<int,dd4hep::sim::Geant4Particle*>+;
71 #pragma link C++ class std::map<int,dd4hep::sim::Geant4Particle*>::iterator;
72 #pragma link C++ class std::map<int,dd4hep::sim::Geant4Particle*>::const_iterator;
73 
74 #ifdef R__MACOSX
75 // We only need these declarations for the clang compiler
76 #pragma link C++ function operator==( const std::map<int,dd4hep::sim::Geant4Particle*>::iterator&, const std::map<int,dd4hep::sim::Geant4Particle*>::iterator& );
77 #pragma link C++ function operator!=( const std::map<int,dd4hep::sim::Geant4Particle*>::iterator&, const std::map<int,dd4hep::sim::Geant4Particle*>::iterator& );
78 #endif
79 
81 #pragma link C++ class dd4hep::sim::Geant4HitData+;
82 namespace dd4hep { namespace sim { typedef Geant4HitData* Geant4HitData_ptr_t; }}
83 #pragma link C++ typedef dd4hep::sim::Geant4HitData_ptr_t;
84 #pragma link C++ class std::vector<dd4hep::sim::Geant4HitData_ptr_t>+;
85 #pragma link C++ class dd4hep::sim::Geant4HitData::Contribution+;
86 #pragma link C++ class dd4hep::sim::Geant4HitData::Contributions+;
87 
89 #pragma link C++ class dd4hep::sim::Geant4Tracker+;
90 #pragma link C++ class dd4hep::sim::Geant4Tracker::Hit+;
91 #pragma link C++ class std::vector<dd4hep::sim::Geant4Tracker::Hit*>+;
92 
94 #pragma link C++ class dd4hep::sim::Geant4Calorimeter+;
95 #pragma link C++ class dd4hep::sim::Geant4Calorimeter::Hit+;
96 #pragma link C++ class std::vector<dd4hep::sim::Geant4Calorimeter::Hit*>+;
97 
98 #endif
99 
100 #ifdef __DDG4_STANDALONE_DICTIONARIES__
101 /*
102  * dd4hep namespace declaration
103  */
104 namespace dd4hep {
105 
106  /*
107  * Simulation namespace declaration
108  */
109  namespace sim {
110 #define NO_CALL { throw "This function shoule never ever be called!"; }
111  inline SimpleRun::SimpleRun() : runID(0), numEvents(0) { }
114  inline SimpleRun::~SimpleRun() { }
116  inline SimpleEvent::SimpleEvent() : runID(0), eventID(0) { }
118  inline SimpleEvent::~SimpleEvent() { }
119 
121  inline DataExtension::~DataExtension() { }
125  inline Geant4Particle::Geant4Particle() { }
129  inline void Geant4Particle::removeDaughter(int) { NO_CALL }
131  inline Geant4HitData::Geant4HitData(): cellID(0), flag(0), g4ID(0) { }
133  inline Geant4HitData::~Geant4HitData() { }
137  inline Geant4HitData::Contribution Geant4HitData::extractContribution(const Geant4FastSimSpot*) { return Contribution(); }
139  inline Geant4Tracker::Hit::Hit() : length(0), energyDeposit(0e0) { }
141  //inline Geant4Tracker::Hit::Hit(int, int, double, double) {}
143  inline Geant4Tracker::Hit::~Hit() { }
145  inline void Geant4Tracker::Hit::copyFrom(const Hit&) { }
147  inline Geant4Tracker::Hit& Geant4Tracker::Hit::clear() { return *this; }
149  inline Geant4Tracker::Hit& Geant4Tracker::Hit::storePoint(const G4Step*, const G4StepPoint*) { return *this;}
151  inline Geant4Tracker::Hit& Geant4Tracker::Hit::storePoint(const Geant4FastSimSpot*) { return *this;}
153  inline Geant4Calorimeter::Hit::Hit() : energyDeposit(0e0) { }
155  inline Geant4Calorimeter::Hit::Hit(const Position&) : energyDeposit(0e0) {}
157  inline Geant4Calorimeter::Hit::~Hit() { }
158  }
159 }
160 #undef NO_CALL
161 
162 #endif // __DDG4_STANDALONE_DICTIONARIES__
163 
164 #endif // DDG4_DDG4DICT_H
dd4hep::sim::SimpleRun::SimpleRun
SimpleRun()
Default constructor.
Definition: Geant4Data.cpp:30
dd4hep::sim::Geant4HitData::Contribution
MonteCarloContrib Contribution
Definition: Geant4Data.h:231
dd4hep::sim::Geant4Calorimeter::Hit::~Hit
virtual ~Hit()
Default destructor.
Definition: Geant4Data.cpp:208
dd4hep::sim::Geant4Tracker::Hit::copyFrom
void copyFrom(const Hit &c)
Explicit assignment operation.
Definition: Geant4Data.cpp:133
Geant4Data.h
dd4hep::sim::Geant4Tracker::Hit::~Hit
virtual ~Hit()
Default destructor.
Definition: Geant4Data.cpp:128
dd4hep::sim::Geant4Particle::~Geant4Particle
virtual ~Geant4Particle()
Default destructor.
Definition: Geant4Particle.cpp:54
dd4hep::sim::Geant4HitData::~Geant4HitData
virtual ~Geant4HitData()
Default destructor.
Definition: Geant4Data.cpp:59
dd4hep::sim::ParticleExtension::~ParticleExtension
virtual ~ParticleExtension()
Default destructor.
Definition: Geant4Particle.cpp:38
dd4hep::sim::SimpleEvent::SimpleEvent
SimpleEvent()
Default constructor.
Definition: Geant4Data.cpp:40
dd4hep::sim::Geant4Tracker::Hit::Hit
Hit()
Default constructor.
Definition: Geant4Data.cpp:104
dd4hep::sim::SimpleRun::~SimpleRun
virtual ~SimpleRun()
Default destructor.
Definition: Geant4Data.cpp:35
dd4hep::sim::Geant4Calorimeter::Hit::Hit
Hit()
Default constructor (for ROOT)
Definition: Geant4Data.cpp:198
dd4hep::sim::Geant4HitData::Geant4HitData
Geant4HitData()
Default constructor.
Definition: Geant4Data.cpp:54
Memory.h
dd4hep::Position
ROOT::Math::XYZVector Position
Definition: Objects.h:81
dd4hep::sim::Geant4Particle::Geant4Particle
Geant4Particle()
not persistent
Definition: Geant4Particle.cpp:42
dd4hep::sim::DataExtension::~DataExtension
virtual ~DataExtension()
Default destructor.
Definition: Geant4Data.cpp:50
dd4hep
Namespace for the AIDA detector description toolkit.
Definition: AlignmentsCalib.h:28
dd4hep::sim::Geant4HitData::extractContribution
static Contribution extractContribution(const G4Step *step)
Extract the MC contribution for a given hit from the step information.
Definition: Geant4Data.cpp:64
Geant4Particle.h
dd4hep::sim::Geant4Tracker::Hit::storePoint
Hit & storePoint(const G4Step *step, const G4StepPoint *point)
Store Geant4 point and step information into tracker hit structure.
Definition: Geant4Data.cpp:154
dd4hep::sim::Geant4Tracker::Hit::clear
Hit & clear()
Clear hit content.
Definition: Geant4Data.cpp:144
dd4hep::sim::Geant4Particle::removeDaughter
void removeDaughter(int id_daughter)
Remove daughter from set.
Definition: Geant4Particle.cpp:110
dd4hep::sim::SimpleEvent::~SimpleEvent
virtual ~SimpleEvent()
Default destructor.
Definition: Geant4Data.cpp:45