Geant4  10.02.p02
G4InuclParticleNames.cc
Go to the documentation of this file.
1 //
2 // ********************************************************************
3 // * License and Disclaimer *
4 // * *
5 // * The Geant4 software is copyright of the Copyright Holders of *
6 // * the Geant4 Collaboration. It is provided under the terms and *
7 // * conditions of the Geant4 Software License, included in the file *
8 // * LICENSE and available at http://cern.ch/geant4/license . These *
9 // * include a list of copyright holders. *
10 // * *
11 // * Neither the authors of this software system, nor their employing *
12 // * institutes,nor the agencies providing financial support for this *
13 // * work make any representation or warranty, express or implied, *
14 // * regarding this software system or assume any liability for its *
15 // * use. Please see the license in the file LICENSE and URL above *
16 // * for the full disclaimer and the limitation of liability. *
17 // * *
18 // * This code implementation is the result of the scientific and *
19 // * technical work of the GEANT4 collaboration. *
20 // * By using, copying, modifying or distributing the software (or *
21 // * any work based on the software) you agree to acknowledge its *
22 // * use in resulting scientific publications, and indicate your *
23 // * acceptance of all terms of the Geant4 Software license. *
24 // ********************************************************************
25 //
26 // $Id: G4InuclParticleNames.hh 69638 2013-05-09 04:26:00Z mkelsey $
27 //
28 // Defines enums to map G4InuclElementaryParticle type codes to human
29 // readable names. Meant to replace similar local enums scattered through
30 // the code.
31 
32 #include "G4InuclParticleNames.hh"
33 
34 using namespace G4InuclParticleNames;
35 
36 
37 // Convert enum entries to strings
38 
40  switch (ptype) {
41  case nuclei: return "nuclei"; break;
42  case proton: return "proton"; break;
43  case neutron: return "neutron"; break;
44  case pionPlus: return "pionPlus"; break;
45  case pionMinus: return "pionMinus"; break;
46  case pionZero: return "pionZero"; break;
47  case photon: return "photon"; break;
48  case kaonPlus: return "kaonPlus"; break;
49  case kaonMinus: return "kaonMinus"; break;
50  case kaonZero: return "kaonZero"; break;
51  case kaonZeroBar: return "kaonZeroBar"; break;
52  case lambda: return "lambda"; break;
53  case sigmaPlus: return "sigmaPlus"; break;
54  case sigmaZero: return "sigmaZero"; break;
55  case sigmaMinus: return "sigmaMinus"; break;
56  case xiZero: return "xiZero"; break;
57  case xiMinus: return "xiMinus"; break;
58  case omegaMinus: return "omegaMinus"; break;
59  case deuteron: return "deuteron"; break;
60  case triton: return "triton"; break;
61  case He3: return "He3"; break;
62  case alpha: return "alpha"; break;
63  case antiProton: return "antiProton"; break;
64  case antiNeutron: return "antiNeutron"; break;
65  case antiDeuteron: return "antiDeuteron"; break;
66  case antiTriton: return "antiTriton"; break;
67  case antiHe3: return "antiHe3"; break;
68  case antiAlpha: return "antiAlpha"; break;
69  case diproton: return "diproton"; break;
70  case unboundPN: return "unboundPN"; break;
71  case dineutron: return "dineutron"; break;
72  case electronNu: return "electronNu"; break;
73  case muonNu: return "muonNu"; break;
74  case tauNu: return "tauNu"; break;
75  case antiElectronNu: return "antiElectronNu"; break;
76  case antiMuonNu: return "antiMuonNu"; break;
77  case antiTauNu: return "antiTauNu"; break;
78  case WMinus: return "WMinus"; break;
79  case WPlus: return "WPlus"; break;
80  case Zzero: return "Zzero"; break;
81  case electron: return "electron"; break;
82  case muonMinus: return "muonMinus"; break;
83  case tauMinus: return "tauMinus"; break;
84  case positron: return "positron"; break;
85  case muonPlus: return "muonPlus"; break;
86  case tauPlus: return "tauPlus"; break;
87  default: ;
88  }
89  return "UNKNOWN";
90 }
91 
93  switch (ptype) {
94  case nuc: return "nuc"; break;
95  case pro: return "pro"; break;
96  case neu: return "neu"; break;
97  case pip: return "pip"; break;
98  case pim: return "pim"; break;
99  case pi0: return "pi0"; break;
100  case gam: return "gam"; break;
101  case kpl: return "kpl"; break;
102  case kmi: return "kmi"; break;
103  case k0: return "k0"; break;
104  case k0b: return "k0b"; break;
105  case lam: return "lam"; break;
106  case sp: return "sp"; break;
107  case s0: return "s0"; break;
108  case sm: return "sm"; break;
109  case xi0: return "xi0"; break;
110  case xim: return "xim"; break;
111  case om: return "om"; break;
112  case deu: return "deu"; break;
113  case ap: return "ap"; break;
114  case an: return "an"; break;
115  case ade: return "ade"; break;
116  case atr: return "atr"; break;
117  case ahe: return "ahe"; break;
118  case aal: return "aal"; break;
119  case pp: return "pp"; break;
120  case pn: return "pn"; break;
121  case nn: return "nn"; break;
122  case enu: return "enu"; break;
123  case mnu: return "mnu"; break;
124  case tnu: return "tnu"; break;
125  case aenu: return "aenu"; break;
126  case amnu: return "amnu"; break;
127  case atnu: return "atnu"; break;
128  case wm: return "wm"; break;
129  case wp: return "wp"; break;
130  case z0: return "z0"; break;
131  case ele: return "ele"; break;
132  case mum: return "mum"; break;
133  case tm: return "tm"; break;
134  case pos: return "pos"; break;
135  case mup: return "mup"; break;
136  case tp: return "tp"; break;
137  default: ;
138  }
139  return "?";
140 }
int G4int
Definition: G4Types.hh:78
const char * nameShort(G4int ptype)
const char * nameLong(G4int ptype)