Geant4 VMC Version 6.6
Loading...
Searching...
No Matches
TG4ProcessMap.h
Go to the documentation of this file.
1#ifndef TG4_PROCESS_MAP_H
2#define TG4_PROCESS_MAP_H
3
4//------------------------------------------------
5// The Geant4 Virtual Monte Carlo package
6// Copyright (C) 2007 - 2022 Ivana Hrivnacova
7// All rights reserved.
8//
9// For the licensing terms see geant4_vmc/LICENSE.
10// Contact: root-vmc@cern.ch
11//-------------------------------------------------
12
17
18#include "TG4G3Control.h"
19
20#include <globals.hh>
21
22#include <TMCProcess.h>
23
24#include <map>
25
26class G4VProcess;
27
35
37{
38 public:
40 TG4ProcessMap(const TG4ProcessMap& right) = delete;
41 TG4ProcessMap& operator=(const TG4ProcessMap& right) = delete;
43
44 // static access method
45 static TG4ProcessMap* Instance();
46
47 // methods
48 G4bool Add(G4int subType, TMCProcess mcProcess, TG4G3Control g3Control);
49 void PrintAll() const;
50 void Clear();
51
52 // get methods
53 std::pair<TMCProcess, TG4G3Control> GetCodes(const G4VProcess* process) const;
54 TMCProcess GetMCProcess(const G4VProcess* process) const;
55 TG4G3Control GetControl(const G4VProcess* process) const;
56 G4String GetMCProcessName(const G4VProcess* process) const;
57 G4String GetControlName(const G4VProcess* process) const;
58
59 private:
60 // methods
61 G4bool IsDefined(G4int subType);
62
63 // static data members
65
66 // data members
67 std::map<G4int, std::pair<TMCProcess, TG4G3Control>> fMap;
68};
69
70// inline methods
71
77
78#endif // TG4_PROCESS_MAP_H
Definition of the enumerations TG4G3Control, TG4G3ControlValue.
Maps G4 process sub types to TMCProcess and TG4G3Control codes.
TG4G3Control GetControl(const G4VProcess *process) const
void PrintAll() const
std::pair< TMCProcess, TG4G3Control > GetCodes(const G4VProcess *process) const
std::map< G4int, std::pair< TMCProcess, TG4G3Control > > fMap
map container
static TG4ProcessMap * Instance()
TMCProcess GetMCProcess(const G4VProcess *process) const
TG4ProcessMap(const TG4ProcessMap &right)=delete
G4String GetMCProcessName(const G4VProcess *process) const
G4bool Add(G4int subType, TMCProcess mcProcess, TG4G3Control g3Control)
G4String GetControlName(const G4VProcess *process) const
G4bool IsDefined(G4int subType)
static TG4ProcessMap * fgInstance
this instance
TG4ProcessMap & operator=(const TG4ProcessMap &right)=delete
TG4G3Control
Enumeration for G3 types of physics processes controls.