Geant4
10.02.p03
G4TrackingInformation.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
// $Id: G4TrackingInformation.hh 94218 2015-11-09 08:24:48Z gcosmo $
27
//
28
// Author: Mathieu Karamitros, kara@cenbg.in2p3.fr
29
30
// The code is developed in the framework of the ESA AO7146
31
//
32
// We would be very happy hearing from you, send us your feedback! :)
33
//
34
// In order for Geant4-DNA to be maintained and still open-source,
35
// article citations are crucial.
36
// If you use Geant4-DNA chemistry and you publish papers about your software,
37
// in addition to the general paper on Geant4-DNA:
38
//
39
// Int. J. Model. Simul. Sci. Comput. 1 (2010) 157–178
40
//
41
// we would be very happy if you could please also cite the following
42
// reference papers on chemistry:
43
//
44
// J. Comput. Phys. 274 (2014) 841-882
45
// Prog. Nucl. Sci. Tec. 2 (2011) 503-508
46
47
#ifndef G4TRACKINGINFORMATION_HH
48
#define G4TRACKINGINFORMATION_HH
49
50
#include "
globals.hh
"
51
#include <vector>
52
#include <map>
53
#include "G4StepStatus.hh"
54
#include "
G4ThreeVector.hh
"
55
#include "
G4TouchableHandle.hh
"
56
#include "
G4TrackState.hh
"
57
#include "
G4memory.hh
"
58
#include "
G4ITStepProcessorState_Lock.hh
"
59
60
class
G4ITStepProcessor
;
61
62
typedef
std::vector<G4int>
G4SelectedAtRestDoItVector
;
63
typedef
std::vector<G4int>
G4SelectedAlongStepDoItVector
;
64
typedef
std::vector<G4int>
G4SelectedPostStepDoItVector
;
65
typedef
std::vector<G4int>
G4SelectedPostStepAtTimeDoItVector
;
66
67
class
G4Trajectory_Lock
;
68
class
G4Track;
69
struct
G4ProcessState_Lock
;
70
class
G4TrackingInformation
;
71
class
G4SaveNavigatorState_Lock;
72
struct
G4ITNavigatorState_Lock;
73
80
class
G4TrackingInformation
81
{
82
public
:
83
G4TrackingInformation
();
84
~G4TrackingInformation
();
85
86
//________________________________________________
91
inline
bool
IsLeadingStep
()
92
{
93
return
fStepLeader
;
94
}
95
inline
void
SetLeadingStep
(
bool
value)
96
{
97
fStepLeader
= value;
98
}
99
100
//________________________________________________
105
G4shared_ptr<G4ProcessState_Lock>
GetProcessState
(
size_t
index
);
106
107
inline
void
RecordProcessState
(G4shared_ptr<G4ProcessState_Lock>,
108
size_t
index);
109
110
//___________________________________________________
111
112
void
SetStepProcessorState
(
G4ITStepProcessorState_Lock
*);
113
G4ITStepProcessorState_Lock
*
GetStepProcessorState
();
114
115
/*
116
std::map<int,G4VTrackStateHandle> fTrackStates;
117
std::map<void*,G4VTrackStateHandle> fMultipleTrackStates;
118
119
void SetTrackState(void* adress, G4VTrackStateHandle state)
120
{
121
fMultipleTrackStates[adress] = state;
122
}
123
G4VTrackStateHandle GetTrackState(void* adress)
124
{
125
return fMultipleTrackStates[adress];
126
}
127
128
void SetTrackState(G4VTrackStateHandle state)
129
{
130
fTrackStates[state->GetID()] = state;
131
}
132
template<typename T> G4VTrackStateHandle GetTrackState()
133
{
134
return fTrackStates[G4TrackStateID<T>::GetID()] ;
135
}
136
*/
137
138
G4TrackStateManager
&
GetTrackStateManager
()
139
{
140
return
fTrackStateManager
;
141
}
142
/*
143
G4TrackStateManager& GetTrackStateManager() const
144
{
145
return fTrackStateManager;
146
}
147
*/
148
inline
G4Trajectory_Lock
*
GetTrajectory_Lock
()
149
{
150
return
fpTrajectory_Lock
;
151
}
152
153
inline
void
SetTrajectory_Lock
(
G4Trajectory_Lock
* trajLock)
154
{
155
fpTrajectory_Lock
= trajLock;
156
}
157
158
void
RecordCurrentPositionNTime
(G4Track*);
159
inline
const
G4ThreeVector
&
GetPreStepPosition
()
const
;
160
inline
G4double
GetPreStepLocalTime
()
const
;
161
inline
G4double
GetPreStepGlobalTime
()
const
;
162
163
inline
void
SetNavigatorState
(G4ITNavigatorState_Lock *);
164
inline
G4ITNavigatorState_Lock*
GetNavigatorState
()
const
;
165
166
//-------------
167
protected
:
168
//-------------
169
friend
class
G4ITStepProcessor
;
170
//_______________________________________________________
171
G4bool
fStepLeader
;
172
//_______________________________________________________
173
G4Trajectory_Lock
*
fpTrajectory_Lock
;
174
175
G4TrackStateManager
fTrackStateManager
;
176
177
//_______________________________________________________
178
G4ThreeVector
fRecordedTrackPosition
;
179
G4double
fRecordedTrackLocalTime
;
180
G4double
fRecordedTrackGlobalTime
;
181
182
//_______________________________________________________
183
G4ITNavigatorState_Lock*
fNavigatorState
;
184
// G4SaveNavigatorState_Lock* fNavigatorState;
185
186
//_______________________________________________________
191
// std::vector<G4ProcessState_Lock*> fProcessState;
192
std::vector<G4shared_ptr<G4ProcessState_Lock> >
fProcessState
;
193
194
//_______________________________________________________
195
G4ITStepProcessorState_Lock
*
fpStepProcessorState
;
196
197
//_______________________________________________________
201
G4TrackingInformation
(
const
G4TrackingInformation
& other);
202
207
G4TrackingInformation
&
operator=
(
const
G4TrackingInformation
& other);
208
};
209
210
inline
211
void
G4TrackingInformation::SetStepProcessorState
(
G4ITStepProcessorState_Lock
* state)
212
{
213
fpStepProcessorState
= state;
214
}
215
216
inline
G4ITStepProcessorState_Lock
*
G4TrackingInformation::GetStepProcessorState
()
217
{
218
return
fpStepProcessorState
;
219
}
220
/*
221
inline void G4TrackingInformation::RecordProcessState(G4ProcessState_Lock* state,
222
size_t index)
223
{
224
// G4cout << "G4TrackingInformation::RecordProcessState" << G4endl;
225
fProcessState[index] = state;
226
}*/
227
228
inline
229
void
G4TrackingInformation::RecordProcessState
(G4shared_ptr<G4ProcessState_Lock> state,
230
size_t
index
)
231
{
232
// G4cout << "G4TrackingInformation::RecordProcessState" << G4endl;
233
fProcessState
[
index
] = state;
234
}
235
236
inline
G4double
G4TrackingInformation::GetPreStepGlobalTime
()
const
237
{
238
return
fRecordedTrackGlobalTime
;
239
}
240
241
inline
G4double
G4TrackingInformation::GetPreStepLocalTime
()
const
242
{
243
return
fRecordedTrackLocalTime
;
244
}
245
246
inline
const
G4ThreeVector
&
G4TrackingInformation::GetPreStepPosition
()
const
247
{
248
return
fRecordedTrackPosition
;
249
}
250
251
inline
void
G4TrackingInformation::SetNavigatorState
(G4ITNavigatorState_Lock* state)
252
{
253
// G4cout << "Set Navigator state : " << state << G4endl;
254
fNavigatorState
= state;
255
}
256
257
inline
G4ITNavigatorState_Lock*
G4TrackingInformation::GetNavigatorState
()
const
258
{
259
return
fNavigatorState
;
260
}
261
262
#endif // G4TRACKINGINFORMATION_HH
G4TrackingInformation::IsLeadingStep
bool IsLeadingStep()
Definition:
G4TrackingInformation.hh:91
G4ITStepProcessor
Definition:
G4ITStepProcessor.hh:154
CLHEP::Hep3Vector
Definition:
ThreeVector.h:41
G4TrackingInformation::fRecordedTrackPosition
G4ThreeVector fRecordedTrackPosition
Definition:
G4TrackingInformation.hh:178
G4TrackingInformation::fpTrajectory_Lock
G4Trajectory_Lock * fpTrajectory_Lock
Definition:
G4TrackingInformation.hh:173
G4ProcessState_Lock
Definition:
G4VITProcess.hh:59
index
Int_t index
Definition:
brachytherapy/macro.C:7
G4TrackingInformation::SetStepProcessorState
void SetStepProcessorState(G4ITStepProcessorState_Lock *)
Definition:
G4TrackingInformation.hh:211
G4TrackingInformation::fStepLeader
G4bool fStepLeader
Definition:
G4TrackingInformation.hh:171
G4SelectedAtRestDoItVector
std::vector< G4int > G4SelectedAtRestDoItVector
Definition:
G4TrackingInformation.hh:60
G4TrackingInformation::RecordCurrentPositionNTime
void RecordCurrentPositionNTime(G4Track *)
Definition:
G4TrackingInformation.cc:121
G4TrackingInformation::GetPreStepLocalTime
G4double GetPreStepLocalTime() const
Definition:
G4TrackingInformation.hh:241
G4TrackingInformation::operator=
G4TrackingInformation & operator=(const G4TrackingInformation &other)
Definition:
G4TrackingInformation.cc:86
G4TrackingInformation
Definition:
G4TrackingInformation.hh:80
G4TrackStateManager
Definition:
G4TrackState.hh:159
G4TrackingInformation::GetPreStepPosition
const G4ThreeVector & GetPreStepPosition() const
Definition:
G4TrackingInformation.hh:246
G4SelectedPostStepDoItVector
std::vector< G4int > G4SelectedPostStepDoItVector
Definition:
G4TrackingInformation.hh:64
G4TrackingInformation::SetTrajectory_Lock
void SetTrajectory_Lock(G4Trajectory_Lock *trajLock)
Definition:
G4TrackingInformation.hh:153
G4Trajectory_Lock
Definition:
ITTrackingInteractivity.cc:52
G4TrackState.hh
G4TrackingInformation::GetNavigatorState
G4ITNavigatorState_Lock * GetNavigatorState() const
Definition:
G4TrackingInformation.hh:257
G4TrackingInformation::G4TrackingInformation
G4TrackingInformation()
Definition:
G4TrackingInformation.cc:41
G4memory.hh
G4TrackingInformation::fRecordedTrackLocalTime
G4double fRecordedTrackLocalTime
Definition:
G4TrackingInformation.hh:179
G4bool
bool G4bool
Definition:
G4Types.hh:79
G4TrackingInformation::GetStepProcessorState
G4ITStepProcessorState_Lock * GetStepProcessorState()
Definition:
G4TrackingInformation.hh:216
globals.hh
G4TouchableHandle.hh
G4TrackingInformation::fTrackStateManager
G4TrackStateManager fTrackStateManager
Definition:
G4TrackingInformation.hh:175
G4SelectedAlongStepDoItVector
std::vector< G4int > G4SelectedAlongStepDoItVector
Definition:
G4TrackingInformation.hh:63
G4TrackingInformation::SetLeadingStep
void SetLeadingStep(bool value)
Definition:
G4TrackingInformation.hh:95
G4TrackingInformation::GetProcessState
G4shared_ptr< G4ProcessState_Lock > GetProcessState(size_t index)
Definition:
G4TrackingInformation.cc:107
G4TrackingInformation::fNavigatorState
G4ITNavigatorState_Lock * fNavigatorState
Definition:
G4TrackingInformation.hh:183
G4SelectedPostStepAtTimeDoItVector
std::vector< G4int > G4SelectedPostStepAtTimeDoItVector
Definition:
G4TrackingInformation.hh:65
G4TrackingInformation::SetNavigatorState
void SetNavigatorState(G4ITNavigatorState_Lock *)
Definition:
G4TrackingInformation.hh:251
G4TrackingInformation::fRecordedTrackGlobalTime
G4double fRecordedTrackGlobalTime
Definition:
G4TrackingInformation.hh:180
G4TrackingInformation::GetPreStepGlobalTime
G4double GetPreStepGlobalTime() const
Definition:
G4TrackingInformation.hh:236
G4TrackingInformation::fpStepProcessorState
G4ITStepProcessorState_Lock * fpStepProcessorState
Definition:
G4TrackingInformation.hh:195
G4TrackingInformation::GetTrajectory_Lock
G4Trajectory_Lock * GetTrajectory_Lock()
Definition:
G4TrackingInformation.hh:148
G4double
double G4double
Definition:
G4Types.hh:76
G4ThreeVector.hh
G4TrackingInformation::RecordProcessState
void RecordProcessState(G4shared_ptr< G4ProcessState_Lock >, size_t index)
Definition:
G4TrackingInformation.hh:229
G4TrackingInformation::GetTrackStateManager
G4TrackStateManager & GetTrackStateManager()
Definition:
G4TrackingInformation.hh:138
G4TrackingInformation::fProcessState
std::vector< G4shared_ptr< G4ProcessState_Lock > > fProcessState
Definition:
G4TrackingInformation.hh:192
G4TrackingInformation::~G4TrackingInformation
~G4TrackingInformation()
Definition:
G4TrackingInformation.cc:53
G4ITStepProcessorState_Lock
Definition:
G4ITStepProcessorState_Lock.hh:38
G4ITStepProcessorState_Lock.hh
Geant4
Geant4.10.02.p03
source
processes
electromagnetic
dna
management
include
G4TrackingInformation.hh
Generated by
1.8.13