ECCE @ EIC Software
Reference for
ECCE @ EIC
simulation and reconstruction software on GitHub
Home page
Related Pages
Modules
Namespaces
Classes
Files
External Links
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Groups
Pages
G4MaterialCutsCouple.hh
Go to the documentation of this file.
Or view
the newest version in sPHENIX GitHub for file G4MaterialCutsCouple.hh
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
//
28
//
29
// ------------------------------------------------------------
30
// GEANT 4 class header file
31
//
32
//
33
// Class Description
34
// This class is
35
//
36
// ------------------------------------------------------------
37
// First Implementation 17 Sep. 2002 H.Kurahige
38
// ------------------------------------------------------------
39
40
#ifndef G4MaterialCutsCouple_h
41
#define G4MaterialCutsCouple_h 1
42
43
#include "
globals.hh
"
44
#include "
G4ios.hh
"
45
46
class
G4Material
;
47
#include "
G4ProductionCuts.hh
"
48
49
class
G4MaterialCutsCouple
50
{
51
public
:
// with description
52
// constructor
53
G4MaterialCutsCouple
();
54
G4MaterialCutsCouple
(
const
G4Material
*,
G4ProductionCuts
* cut=0);
55
56
// copy constructor
57
G4MaterialCutsCouple
(
const
G4MaterialCutsCouple
&
right
);
58
59
G4MaterialCutsCouple
&
operator=
(
const
G4MaterialCutsCouple
&right);
60
61
public
:
62
// destructor
63
virtual
~G4MaterialCutsCouple
();
64
65
// equal opperators
66
G4bool
operator==
(
const
G4MaterialCutsCouple
&right)
const
;
67
G4bool
operator!=
(
const
G4MaterialCutsCouple
&right)
const
;
68
69
public
:
// with description
70
void
SetMaterial
(
const
G4Material
*);
71
// Set pointer to material
72
73
const
G4Material
*
GetMaterial
()
const
;
74
// Get pointer to material
75
76
void
SetProductionCuts
(
G4ProductionCuts
*);
77
// Set pointer to production cuts
78
79
G4ProductionCuts
*
GetProductionCuts
()
const
;
80
// Get pointer to production cuts
81
82
G4bool
IsRecalcNeeded
()
const
;
83
// return true if cut and/or material has been modified
84
// after last calculation of PhysicsTable
85
86
void
PhysicsTableUpdated
();
87
// inform end of calculation of PhysicsTable
88
89
void
SetIndex
(
G4int
idx
);
90
G4int
GetIndex
()
const
;
91
// Set/Get the index number in G4ProductionCutsTable
92
93
void
SetUseFlag
(
G4bool
flg=
true
);
94
G4bool
IsUsed
()
const
;
95
96
private
:
97
G4bool
isMaterialModified
;
98
const
G4Material
*
fMaterial
;
99
G4ProductionCuts
*
fCuts
;
100
G4int
indexNumber
;
101
G4bool
isUsedInGeometry
;
102
};
103
104
#include "
G4ProductionCuts.hh
"
105
inline
106
void
G4MaterialCutsCouple::SetIndex
(
G4int
idx
)
107
{
indexNumber
=
idx
; }
108
109
inline
110
G4int
G4MaterialCutsCouple::GetIndex
()
const
111
{
return
indexNumber
; }
112
113
inline
114
void
G4MaterialCutsCouple::SetUseFlag
(
G4bool
flg)
115
{
isUsedInGeometry
= flg; }
116
117
inline
118
G4bool
G4MaterialCutsCouple::IsUsed
()
const
119
{
return
isUsedInGeometry
; }
120
121
inline
122
void
G4MaterialCutsCouple::SetProductionCuts
(
G4ProductionCuts
* aCut)
123
{
fCuts
= aCut; }
124
125
inline
126
G4ProductionCuts
*
G4MaterialCutsCouple::GetProductionCuts
()
const
127
{
return
fCuts
; }
128
129
inline
130
G4bool
G4MaterialCutsCouple::operator==
(
const
G4MaterialCutsCouple
&
right
)
const
131
{
132
return
(
this
== &right);
133
}
134
135
inline
136
G4bool
G4MaterialCutsCouple::operator!=
(
const
G4MaterialCutsCouple
&
right
)
const
137
{
138
return
(
this
!= &right);
139
}
140
141
inline
142
void
G4MaterialCutsCouple::SetMaterial
(
const
G4Material
*
material
)
143
{
144
fMaterial
=
material
;
145
isMaterialModified
=
true
;
146
}
147
148
inline
149
const
G4Material
*
G4MaterialCutsCouple::GetMaterial
()
const
150
{
151
return
fMaterial
;
152
}
153
154
inline
155
G4bool
G4MaterialCutsCouple::IsRecalcNeeded
()
const
156
{
157
G4bool
isCutModified =
false
;
158
if
(
fCuts
!=0 ) isCutModified =
fCuts
->
IsModified
();
159
return
(
isMaterialModified
|| isCutModified);
160
}
161
162
inline
163
void
G4MaterialCutsCouple::PhysicsTableUpdated
()
164
{
165
if
(
fCuts
!=0 )
fCuts
->
PhysicsTableUpdated
();
166
isMaterialModified
=
false
;
167
}
168
169
170
#endif
171
172
173
174
175
176
geant4
tree
geant4-10.6-release
source
processes
cuts
include
G4MaterialCutsCouple.hh
Built by
Jin Huang
. updated:
Wed Jun 29 2022 17:25:28
using
1.8.2 with
ECCE GitHub integration