Geant4
10.02.p02
Main Page
Related Pages
Modules
Namespaces
Classes
Files
File List
File Members
G4PrimaryTransformer.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
//
26
//
27
// $Id: G4PrimaryTransformer.hh 72252 2013-07-12 09:04:11Z gcosmo $
28
//
29
30
#ifndef G4PromaryTransformer_h
31
#define G4PromaryTransformer_h 1
32
33
#include "
G4TrackVector.hh
"
34
#include "
G4ParticleTable.hh
"
35
#include "
globals.hh
"
36
class
G4Event
;
37
class
G4PrimaryVertex
;
38
#include "
G4PrimaryParticle.hh
"
39
#include "
G4DynamicParticle.hh
"
40
41
// class description:
42
//
43
// This class is exclusively used by G4EventManager for the conversion
44
// from G4PrimaryVertex/G4PrimaryParticle to G4DynamicParticle/G4Track.
45
//
46
47
class
G4PrimaryTransformer
48
{
49
public
:
50
G4PrimaryTransformer
();
51
virtual
~G4PrimaryTransformer
();
52
53
G4TrackVector
*
GimmePrimaries
(
G4Event
* anEvent,
G4int
trackIDCounter=0);
54
void
CheckUnknown
();
55
56
protected
:
57
G4TrackVector
TV
;
58
G4ParticleTable
*
particleTable
;
59
G4int
verboseLevel
;
60
G4int
trackID
;
61
62
G4ParticleDefinition
*
unknown
;
63
G4bool
unknownParticleDefined
;
64
G4ParticleDefinition
*
opticalphoton
;
65
G4bool
opticalphotonDefined
;
66
67
G4int
nWarn
;
68
69
public
:
70
inline
void
SetVerboseLevel
(
G4int
vl)
71
{ verboseLevel = vl; };
72
73
public
:
//with description
74
void
SetUnknnownParticleDefined
(
G4bool
vl);
75
// By invoking this Set method, the user can alter the treatment of unknown
76
// particle. The ideal place to invoke this method is in the BeginOfRunAction.
77
78
inline
G4bool
GetUnknownParticleDefined
()
const
79
{
return
unknownParticleDefined
; }
80
81
protected
:
82
void
GenerateTracks
(
G4PrimaryVertex
* primaryVertex);
83
void
GenerateSingleTrack
(
G4PrimaryParticle
* primaryParticle,
84
G4double
x0,
G4double
y0,
G4double
z0
,
G4double
t0,
G4double
wv);
85
void
SetDecayProducts
(
G4PrimaryParticle
* mother,
86
G4DynamicParticle
* motherDP);
87
G4bool
CheckDynamicParticle
(
G4DynamicParticle
*DP);
88
89
protected
:
//with description
90
// Following two virtual methods are provided to customize the use of PrimaryTransformer
91
// for particle types exotic to Geant4.
92
93
virtual
G4ParticleDefinition
*
GetDefinition
(
G4PrimaryParticle
*
pp
);
94
// Return appropriate G4ParticleDefinition w.r.t. the primary particle.
95
// If NULL is returned, the particle will not be treated as a track, but its daughters
96
// will be examined in case it has "pre-assigned decay products".
97
98
virtual
G4bool
IsGoodForTrack
(
G4ParticleDefinition
*pd);
99
// Return true if a primary particle should be converted into a track.
100
// By default, all particles of non-shortlived and shortlived with valid decay
101
// tables are converted.
102
};
103
104
#endif
105
106
G4PrimaryTransformer::opticalphotonDefined
G4bool opticalphotonDefined
Definition:
G4PrimaryTransformer.hh:65
G4PrimaryTransformer::GimmePrimaries
G4TrackVector * GimmePrimaries(G4Event *anEvent, G4int trackIDCounter=0)
Definition:
G4PrimaryTransformer.cc:70
G4DynamicParticle
Definition:
G4DynamicParticle.hh:73
G4DynamicParticle.hh
G4PrimaryTransformer::CheckDynamicParticle
G4bool CheckDynamicParticle(G4DynamicParticle *DP)
Definition:
G4PrimaryTransformer.cc:306
G4PrimaryTransformer::nWarn
G4int nWarn
Definition:
G4PrimaryTransformer.hh:67
G4ParticleDefinition
Definition:
G4ParticleDefinition.hh:111
G4int
int G4int
Definition:
G4Types.hh:78
G4TrackVector.hh
G4PrimaryTransformer::opticalphoton
G4ParticleDefinition * opticalphoton
Definition:
G4PrimaryTransformer.hh:64
G4PrimaryParticle.hh
G4PrimaryVertex
Definition:
G4PrimaryVertex.hh:50
G4ParticleTable.hh
G4PrimaryTransformer::SetUnknnownParticleDefined
void SetUnknnownParticleDefined(G4bool vl)
Definition:
G4PrimaryTransformer.cc:296
G4bool
bool G4bool
Definition:
G4Types.hh:79
G4ParticleTable
Definition:
G4ParticleTable.hh:65
G4PrimaryTransformer::trackID
G4int trackID
Definition:
G4PrimaryTransformer.hh:60
G4PrimaryTransformer::SetVerboseLevel
void SetVerboseLevel(G4int vl)
Definition:
G4PrimaryTransformer.hh:70
globals.hh
G4PrimaryTransformer::GenerateTracks
void GenerateTracks(G4PrimaryVertex *primaryVertex)
Definition:
G4PrimaryTransformer.cc:88
G4PrimaryTransformer::IsGoodForTrack
virtual G4bool IsGoodForTrack(G4ParticleDefinition *pd)
Definition:
G4PrimaryTransformer.cc:327
G4PrimaryTransformer::TV
G4TrackVector TV
Definition:
G4PrimaryTransformer.hh:57
G4PrimaryTransformer::unknownParticleDefined
G4bool unknownParticleDefined
Definition:
G4PrimaryTransformer.hh:63
G4InuclParticleNames::z0
Definition:
G4InuclParticleNames.hh:70
G4PrimaryTransformer::GenerateSingleTrack
void GenerateSingleTrack(G4PrimaryParticle *primaryParticle, G4double x0, G4double y0, G4double z0, G4double t0, G4double wv)
Definition:
G4PrimaryTransformer.cc:117
G4TrackVector
std::vector< G4Track * > G4TrackVector
Definition:
G4TrackVector.hh:49
G4InuclParticleNames::pp
Definition:
G4InuclParticleNames.hh:67
G4PrimaryTransformer::CheckUnknown
void CheckUnknown()
Definition:
G4PrimaryTransformer.cc:56
G4PrimaryTransformer::GetUnknownParticleDefined
G4bool GetUnknownParticleDefined() const
Definition:
G4PrimaryTransformer.hh:78
G4PrimaryTransformer
Definition:
G4PrimaryTransformer.hh:47
G4PrimaryTransformer::particleTable
G4ParticleTable * particleTable
Definition:
G4PrimaryTransformer.hh:58
G4PrimaryTransformer::unknown
G4ParticleDefinition * unknown
Definition:
G4PrimaryTransformer.hh:62
G4PrimaryParticle
Definition:
G4PrimaryParticle.hh:68
G4PrimaryTransformer::GetDefinition
virtual G4ParticleDefinition * GetDefinition(G4PrimaryParticle *pp)
Definition:
G4PrimaryTransformer.cc:319
G4PrimaryTransformer::~G4PrimaryTransformer
virtual ~G4PrimaryTransformer()
Definition:
G4PrimaryTransformer.cc:53
G4PrimaryTransformer::verboseLevel
G4int verboseLevel
Definition:
G4PrimaryTransformer.hh:59
G4PrimaryTransformer::G4PrimaryTransformer
G4PrimaryTransformer()
Definition:
G4PrimaryTransformer.cc:43
G4double
double G4double
Definition:
G4Types.hh:76
G4Event
Definition:
G4Event.hh:52
G4PrimaryTransformer::SetDecayProducts
void SetDecayProducts(G4PrimaryParticle *mother, G4DynamicParticle *motherDP)
Definition:
G4PrimaryTransformer.cc:236
geant4.10.02.p02
source
event
include
G4PrimaryTransformer.hh
Generated on Fri Jul 1 2016 14:11:02 for Geant4 by
1.8.8