CMS 3D CMS Logo

PrintGeomSummary.h
Go to the documentation of this file.
1 #ifndef SimG4Core_PrintGeomSummary_H
2 #define SimG4Core_PrintGeomSummary_H
3 
8 
9 #include "G4NavigationHistory.hh"
10 
11 #include <algorithm>
12 #include <iostream>
13 #include <vector>
14 #include <map>
15 #include <string>
16 
17 class BeginOfJob;
18 class BeginOfRun;
19 class DDLogicalPart;
20 class G4LogicalVolume;
21 class G4VPhysicalVolume;
22 class G4VSolid;
23 
24 class PrintGeomSummary : public SimWatcher, public Observer<const BeginOfJob *>, public Observer<const BeginOfRun *> {
25 public:
27  ~PrintGeomSummary() override;
28 
29 private:
30  void update(const BeginOfJob *job) override;
31  void update(const BeginOfRun *run) override;
32  void addSolid(const DDLogicalPart &part);
33  void fillLV(G4LogicalVolume *lv);
34  void fillPV(G4VPhysicalVolume *pv);
35  void dumpSummary(std::ostream &out, std::string name);
36  G4VPhysicalVolume *getTopPV();
37  void addName(std::string name);
38  void printSummary(std::ostream &out);
39 
40 private:
41  std::vector<std::string> nodeNames_;
42  std::map<DDSolidShape, std::string> solidShape_;
43  std::map<std::string, DDSolidShape> solidMap_;
44  G4VPhysicalVolume *theTopPV_;
45  std::vector<G4LogicalVolume *> lvs_, touch_;
46  std::vector<G4VSolid *> sls_;
47  std::vector<G4VPhysicalVolume *> pvs_;
48  std::map<DDSolidShape, std::pair<int, int> > kount_;
49 };
50 
51 #endif
DDSolidShapes.h
PrintGeomSummary::lvs_
std::vector< G4LogicalVolume * > lvs_
Definition: PrintGeomSummary.h:45
Observer
Definition: Observer.h:23
PrintGeomSummary::dumpSummary
void dumpSummary(std::ostream &out, std::string name)
Definition: PrintGeomSummary.cc:158
PrintGeomSummary::pvs_
std::vector< G4VPhysicalVolume * > pvs_
Definition: PrintGeomSummary.h:47
AlCaHLTBitMon_ParallelJobs.p
p
Definition: AlCaHLTBitMon_ParallelJobs.py:153
PrintGeomSummary::~PrintGeomSummary
~PrintGeomSummary() override
Definition: PrintGeomSummary.cc:61
PrintGeomSummary::solidMap_
std::map< std::string, DDSolidShape > solidMap_
Definition: PrintGeomSummary.h:43
PrintGeomSummary::kount_
std::map< DDSolidShape, std::pair< int, int > > kount_
Definition: PrintGeomSummary.h:48
Observer.h
PrintGeomSummary::sls_
std::vector< G4VSolid * > sls_
Definition: PrintGeomSummary.h:46
part
part
Definition: HCALResponse.h:20
SimWatcher.h
PrintGeomSummary::solidShape_
std::map< DDSolidShape, std::string > solidShape_
Definition: PrintGeomSummary.h:42
PrintGeomSummary::addName
void addName(std::string name)
Definition: PrintGeomSummary.cc:194
BeginOfJob
Definition: BeginOfJob.h:8
AlCaHLTBitMon_QueryRunRegistry.string
string
Definition: AlCaHLTBitMon_QueryRunRegistry.py:256
edm::ParameterSet
Definition: ParameterSet.h:36
DDLogicalPart
A DDLogicalPart aggregates information concerning material, solid and sensitveness ....
Definition: DDLogicalPart.h:93
MetAnalyzer.pv
def pv(vc)
Definition: MetAnalyzer.py:7
PrintGeomSummary::theTopPV_
G4VPhysicalVolume * theTopPV_
Definition: PrintGeomSummary.h:44
PrintGeomSummary::getTopPV
G4VPhysicalVolume * getTopPV()
Definition: PrintGeomSummary.cc:190
BeginOfRun
Definition: BeginOfRun.h:6
SimWatcher
Definition: SimWatcher.h:33
PrintGeomSummary::touch_
std::vector< G4LogicalVolume * > touch_
Definition: PrintGeomSummary.h:45
PrintGeomSummary
Definition: PrintGeomSummary.h:24
PrintGeomSummary::printSummary
void printSummary(std::ostream &out)
Definition: PrintGeomSummary.cc:211
PrintGeomSummary::fillPV
void fillPV(G4VPhysicalVolume *pv)
Definition: PrintGeomSummary.cc:151
writedatasetfile.run
run
Definition: writedatasetfile.py:27
PrintGeomSummary::PrintGeomSummary
PrintGeomSummary(edm::ParameterSet const &p)
Definition: PrintGeomSummary.cc:32
PrintGeomSummary::addSolid
void addSolid(const DDLogicalPart &part)
Definition: PrintGeomSummary.cc:90
Skims_PA_cff.name
name
Definition: Skims_PA_cff.py:17
PrintGeomSummary::fillLV
void fillLV(G4LogicalVolume *lv)
Definition: PrintGeomSummary.cc:140
MillePedeFileConverter_cfg.out
out
Definition: MillePedeFileConverter_cfg.py:31
ParameterSet.h
PrintGeomSummary::update
void update(const BeginOfJob *job) override
This routine will be called when the appropriate signal arrives.
Definition: PrintGeomSummary.cc:63
PrintGeomSummary::nodeNames_
std::vector< std::string > nodeNames_
Definition: PrintGeomSummary.h:41