Geant4
10.03
Main Page
Related Pages
Modules
Namespaces
Classes
Files
File List
File Members
HistoManager.hh
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
//
28
//
29
// $Id: HistoManager.hh 75778 2013-11-06 09:40:58Z vnivanch $
30
//
31
//---------------------------------------------------------------------------
32
//
33
// ClassName: HistoManager
34
//
35
// Description: Singleton class to hold parameters and build histograms.
36
// User cannot access to the constructor.
37
// The pointer of the only existing object can be got via
38
// HistoManager::GetPointer() static method.
39
// The first invokation of this static method makes
40
// the singleton object.
41
//
42
// Author: V.Ivanchenko 27/09/00
43
//
44
// Modified:
45
//
46
//----------------------------------------------------------------------------
47
//
48
49
#ifndef HistoManager_h
50
#define HistoManager_h 1
51
52
#include "
globals.hh
"
53
#include "
G4Material.hh
"
54
55
#include "
g4root.hh
"
56
57
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
58
59
class
Histo
;
60
class
G4ParticleDefinition
;
61
class
HistoManagerMessenger
;
62
63
class
HistoManager
64
{
65
public
:
66
67
HistoManager
();
68
69
~HistoManager
();
70
71
void
BeginOfRun
();
72
void
EndOfRun
();
73
74
void
SetVerbose
(
G4int
val);
75
76
inline
void
SetParticleName
(
const
G4String
&);
77
inline
void
SetElementName
(
const
G4String
&);
78
79
inline
void
SetNumberOfBinsE
(
G4int
val);
80
inline
void
SetNumberOfBinsP
(
G4int
val);
81
82
inline
void
SetMinKinEnergy
(
G4double
val);
83
inline
void
SetMaxKinEnergy
(
G4double
val);
84
85
inline
void
SetMinMomentum
(
G4double
val);
86
inline
void
SetMaxMomentum
(
G4double
val);
87
88
inline
void
SetHistoName
(
G4String
& val);
89
90
private
:
91
92
HistoManagerMessenger
*
fMessenger
;
93
G4AnalysisManager
*
fAnalysisManager
;
94
95
const
G4ParticleDefinition
*
fNeutron
;
96
97
G4String
fParticleName
;
98
G4String
fElementName
;
99
100
G4double
fMinKinEnergy
;
101
G4double
fMaxKinEnergy
;
102
G4double
fMinMomentum
;
103
G4double
fMaxMomentum
;
104
105
G4int
fVerbose
;
106
G4int
fBinsE
;
107
G4int
fBinsP
;
108
109
G4String
fHistoName
;
110
};
111
112
inline
void
HistoManager::SetParticleName
(
const
G4String
&
name
)
113
{
114
fParticleName
=
name
;
115
}
116
117
inline
void
HistoManager::SetElementName
(
const
G4String
&
name
)
118
{
119
fElementName
=
name
;
120
}
121
122
inline
void
HistoManager::SetNumberOfBinsE
(
G4int
val)
123
{
124
if
(val>0) {
fBinsE
= val; }
125
}
126
127
inline
void
HistoManager::SetNumberOfBinsP
(
G4int
val)
128
{
129
if
(val>0) {
fBinsP
= val; }
130
}
131
132
inline
void
HistoManager::SetMinKinEnergy
(
G4double
val)
133
{
134
if
(val>0 && val<
fMaxKinEnergy
) {
fMinKinEnergy
= val; }
135
}
136
137
inline
void
HistoManager::SetMaxKinEnergy
(
G4double
val)
138
{
139
if
(val>
fMinKinEnergy
) {
fMaxKinEnergy
= val; }
140
}
141
142
inline
void
HistoManager::SetMinMomentum
(
G4double
val)
143
{
144
if
(val>0 && val<
fMaxMomentum
) {
fMinMomentum
= val; }
145
}
146
147
inline
void
HistoManager::SetMaxMomentum
(
G4double
val)
148
{
149
if
(val>
fMinMomentum
) {
fMaxMomentum
= val; }
150
}
151
152
inline
void
HistoManager::SetHistoName
(
G4String
& val)
153
{
154
fHistoName
= val;
155
}
156
157
#endif
HistoManager::fMinMomentum
G4double fMinMomentum
Definition:
HistoManager.hh:105
HistoManager::fElementName
G4String fElementName
Definition:
HistoManager.hh:101
G4RootAnalysisManager
Definition:
G4RootAnalysisManager.hh:61
Histo
Definition:
Histo.hh:56
HistoManager::SetMinMomentum
void SetMinMomentum(G4double val)
Definition:
HistoManager.hh:145
HistoManagerMessenger
Definition:
HistoManagerMessenger.hh:59
HistoManager
Definition:
HistoManager.hh:44
HistoManager::SetNumberOfBinsE
void SetNumberOfBinsE(G4int val)
Definition:
HistoManager.hh:125
G4InuclParticleNames::name
const char * name(G4int ptype)
Definition:
G4InuclParticleNames.hh:77
G4ParticleDefinition
Definition:
G4ParticleDefinition.hh:72
HistoManager::fBinsP
G4int fBinsP
Definition:
HistoManager.hh:110
G4int
int G4int
Definition:
G4Types.hh:78
HistoManager::HistoManager
HistoManager()
Definition:
HistoManager.cc:39
HistoManager::fMinKinEnergy
G4double fMinKinEnergy
Definition:
HistoManager.hh:103
HistoManager::fMaxKinEnergy
G4double fMaxKinEnergy
Definition:
HistoManager.hh:104
G4Material.hh
HistoManager::BeginOfRun
void BeginOfRun()
Definition:
HistoManager.cc:129
HistoManager::SetMaxMomentum
void SetMaxMomentum(G4double val)
Definition:
HistoManager.hh:150
HistoManager::~HistoManager
~HistoManager()
Definition:
HistoManager.cc:47
HistoManager::fMessenger
HistoManagerMessenger * fMessenger
Definition:
HistoManager.hh:94
HistoManager::fVerbose
G4int fVerbose
Definition:
HistoManager.hh:123
g4root.hh
globals.hh
HistoManager::fMaxMomentum
G4double fMaxMomentum
Definition:
HistoManager.hh:106
HistoManager::SetMaxKinEnergy
void SetMaxKinEnergy(G4double val)
Definition:
HistoManager.hh:140
HistoManager::SetMinKinEnergy
void SetMinKinEnergy(G4double val)
Definition:
HistoManager.hh:135
HistoManager::fParticleName
G4String fParticleName
Definition:
HistoManager.hh:100
HistoManager::fAnalysisManager
G4AnalysisManager * fAnalysisManager
Definition:
HistoManager.hh:95
HistoManager::fBinsE
G4int fBinsE
Definition:
HistoManager.hh:142
HistoManager::SetElementName
void SetElementName(const G4String &)
Definition:
HistoManager.hh:120
HistoManager::fNeutron
const G4ParticleDefinition * fNeutron
Definition:
HistoManager.hh:97
HistoManager::SetVerbose
void SetVerbose(G4int val)
Definition:
HistoManager.hh:95
HistoManager::SetHistoName
void SetHistoName(G4String &val)
Definition:
HistoManager.hh:155
HistoManager::SetParticleName
void SetParticleName(const G4String &)
Definition:
HistoManager.hh:115
G4double
double G4double
Definition:
G4Types.hh:76
HistoManager::EndOfRun
void EndOfRun()
Definition:
HistoManager.cc:145
HistoManager::fHistoName
G4String fHistoName
Definition:
HistoManager.hh:112
HistoManager::SetNumberOfBinsP
void SetNumberOfBinsP(G4int val)
Definition:
HistoManager.hh:130
G4String
Definition:
G4String.hh:45
geant4.10.03
examples
extended
hadronic
Hadr05
include
HistoManager.hh
Generated on Thu Feb 14 2002 02:27:25 for Geant4 by
1.8.8