#include <G4HnManager.hh>
|
| G4HnManager (G4String hnType, const G4AnalysisManagerState &state) |
|
| G4HnManager ()=delete |
|
| ~G4HnManager () override |
|
G4HnInformation * | AddHnInformation (const G4String &name, G4int nofDimensions) |
|
void | ClearData () |
|
G4HnInformation * | GetHnInformation (G4int id, std::string_view functionName, G4bool warn=true) const |
|
G4HnDimensionInformation * | GetHnDimensionInformation (G4int id, G4int dimension, std::string_view functionName, G4bool warn=true) const |
|
const std::vector< G4HnInformation * > & | GetHnVector () const |
|
G4int | GetNofHns () const |
|
G4int | GetNofActiveHns () const |
|
G4String | GetHnType () const |
|
G4bool | IsActive () const |
|
G4bool | IsAscii () const |
|
G4bool | IsPlotting () const |
|
G4bool | IsFileName () const |
|
void | SetActivation (G4bool activation) |
|
void | SetActivation (G4int id, G4bool activation) |
|
void | SetAscii (G4int id, G4bool ascii) |
|
void | SetPlotting (G4int id, G4bool plotting) |
|
void | SetPlotting (G4bool plotting) |
|
void | SetFileName (G4int id, const G4String &fileName) |
|
void | SetFileName (const G4String &fileName) |
|
G4bool | SetAxisIsLog (unsigned int idim, G4int id, G4bool isLogAxis) |
|
G4String | GetName (G4int id) const |
|
G4double | GetUnit (unsigned int idim, G4int id) const |
|
G4bool | GetAxisIsLog (unsigned int idim, G4int id) const |
|
G4bool | GetActivation (G4int id) const |
|
G4bool | GetAscii (G4int id) const |
|
G4bool | GetPlotting (G4int id) const |
|
G4String | GetFileName (G4int id) const |
|
void | SetFileManager (std::shared_ptr< G4VFileManager > fileManager) |
|
| G4BaseAnalysisManager (const G4AnalysisManagerState &state) |
|
| G4BaseAnalysisManager ()=delete |
|
virtual | ~G4BaseAnalysisManager ()=default |
|
G4bool | SetFirstId (G4int firstId) |
|
void | SetLockFirstId (G4bool lockFirstId) |
|
G4int | GetFirstId () const |
|
G4int | GetCycle () const |
|
Definition at line 47 of file G4HnManager.hh.
◆ G4HnManager() [1/2]
Definition at line 41 of file G4HnManager.cc.
43{
44 fMessenger = std::make_unique<G4HnMessenger>(*this);
45}
G4BaseAnalysisManager()=delete
◆ G4HnManager() [2/2]
G4HnManager::G4HnManager |
( |
| ) |
|
|
delete |
◆ ~G4HnManager()
G4HnManager::~G4HnManager |
( |
| ) |
|
|
override |
Definition at line 48 of file G4HnManager.cc.
49{
50 for ( auto info : fHnVector ) {
51 delete info;
52 }
53}
◆ AddHnInformation()
Definition at line 122 of file G4HnManager.cc.
123{
125 fHnVector.push_back(info);
126 ++fNofActiveObjects;
127
128 return info;
129}
◆ ClearData()
void G4HnManager::ClearData |
( |
| ) |
|
Definition at line 132 of file G4HnManager.cc.
133{
134 for ( auto info : fHnVector ) {
135 delete info;
136 }
137 fHnVector.clear();
139}
void SetLockFirstId(G4bool lockFirstId)
◆ GetActivation()
Definition at line 319 of file G4HnManager.cc.
320{
322
323 if (info == nullptr) return true;
324
325 return info->GetActivation();
326}
G4HnInformation * GetHnInformation(G4int id, std::string_view functionName, G4bool warn=true) const
◆ GetAscii()
Definition at line 329 of file G4HnManager.cc.
330{
332
333 if (info == nullptr) return false;
334
335 return info->GetAscii();
336}
◆ GetAxisIsLog()
G4bool G4HnManager::GetAxisIsLog |
( |
unsigned int |
idim, |
|
|
G4int |
id |
|
) |
| const |
Definition at line 309 of file G4HnManager.cc.
310{
312
313 if (info == nullptr) return false;
314
315 return info->GetIsLogAxis(idim);
316}
◆ GetFileName()
Definition at line 349 of file G4HnManager.cc.
350{
352
353 if (info == nullptr) return "";
354
355 return info->GetFileName();
356}
◆ GetHnDimensionInformation()
Definition at line 157 of file G4HnManager.cc.
160{
162 if (info == nullptr) return nullptr;
163
164 return info->GetHnDimensionInformation(dimension);
165}
Referenced by GetUnit().
◆ GetHnInformation()
Definition at line 142 of file G4HnManager.cc.
144{
146 if ( index < 0 || index >=
G4int(fHnVector.size()) ) {
147 if ( warn ) {
148 Warn(fHnType +
" histogram " + to_string(
id) +
" does not exist.",
149 fkClass, functionName);
150 }
151 return nullptr;
152 }
153 return fHnVector[index];
154}
void Warn(const G4String &message, const std::string_view inClass, const std::string_view inFunction)
Referenced by GetActivation(), GetAscii(), GetAxisIsLog(), GetFileName(), GetHnDimensionInformation(), GetName(), GetPlotting(), SetActivation(), SetAscii(), SetAxisIsLog(), SetFileName(), and SetPlotting().
◆ GetHnType()
G4String G4HnManager::GetHnType |
( |
| ) |
const |
|
inline |
◆ GetHnVector()
const std::vector< G4HnInformation * > & G4HnManager::GetHnVector |
( |
| ) |
const |
|
inline |
◆ GetName()
Definition at line 289 of file G4HnManager.cc.
290{
292
293 if (info == nullptr) return "";
294
295 return info->GetName();
296}
◆ GetNofActiveHns()
G4int G4HnManager::GetNofActiveHns |
( |
| ) |
const |
|
inline |
◆ GetNofHns()
G4int G4HnManager::GetNofHns |
( |
| ) |
const |
|
inline |
◆ GetPlotting()
Definition at line 339 of file G4HnManager.cc.
340{
342
343 if (info == nullptr) return false;
344
345 return info->GetPlotting();
346}
◆ GetUnit()
G4double G4HnManager::GetUnit |
( |
unsigned int |
idim, |
|
|
G4int |
id |
|
) |
| const |
Definition at line 299 of file G4HnManager.cc.
300{
302
303 if (info == nullptr) return 1.0;
304
305 return info->fUnit;
306}
G4HnDimensionInformation * GetHnDimensionInformation(G4int id, G4int dimension, std::string_view functionName, G4bool warn=true) const
◆ IsActive()
G4bool G4HnManager::IsActive |
( |
| ) |
const |
Definition at line 168 of file G4HnManager.cc.
169{
170 return ( fNofActiveObjects > 0 );
171}
◆ IsAscii()
G4bool G4HnManager::IsAscii |
( |
| ) |
const |
Definition at line 174 of file G4HnManager.cc.
175{
176 return ( fNofAsciiObjects > 0 );
177}
◆ IsFileName()
G4bool G4HnManager::IsFileName |
( |
| ) |
const |
Definition at line 186 of file G4HnManager.cc.
187{
188 return ( fNofFileNameObjects > 0 );
189}
◆ IsPlotting()
G4bool G4HnManager::IsPlotting |
( |
| ) |
const |
Definition at line 180 of file G4HnManager.cc.
181{
182 return ( fNofPlottingObjects > 0 );
183}
◆ SetActivation() [1/2]
void G4HnManager::SetActivation |
( |
G4bool |
activation | ) |
|
◆ SetActivation() [2/2]
void G4HnManager::SetActivation |
( |
G4int |
id, |
|
|
G4bool |
activation |
|
) |
| |
Definition at line 192 of file G4HnManager.cc.
193{
194
195
197
198 if (info == nullptr) return;
199
201}
◆ SetAscii()
Definition at line 218 of file G4HnManager.cc.
219{
221
222 if (info == nullptr) return;
223
224
225 if ( info->GetAscii() == ascii ) return;
226
227
228 info->SetAscii(ascii);
229 if (ascii) {
230 fNofAsciiObjects++;
231 }
232 else {
233 fNofAsciiObjects--;
234 }
235}
Referenced by G4HnMessenger::SetNewValue().
◆ SetAxisIsLog()
Definition at line 278 of file G4HnManager.cc.
279{
281
282 if (info == nullptr) return false;
283
284 info->SetIsLogAxis(idim, isLog);
285 return true;
286}
◆ SetFileManager()
void G4HnManager::SetFileManager |
( |
std::shared_ptr< G4VFileManager > |
fileManager | ) |
|
|
inline |
Definition at line 155 of file G4HnManager.hh.
156{
157 fFileManager = std::move(fileManager);
158}
◆ SetFileName() [1/2]
void G4HnManager::SetFileName |
( |
const G4String & |
fileName | ) |
|
Definition at line 268 of file G4HnManager.cc.
269{
270
271
272 for ( auto info : fHnVector ) {
274 }
275}
void SetFileName(G4int id, const G4String &fileName)
◆ SetFileName() [2/2]
void G4HnManager::SetFileName |
( |
G4int |
id, |
|
|
const G4String & |
fileName |
|
) |
| |
◆ SetPlotting() [1/2]
void G4HnManager::SetPlotting |
( |
G4bool |
plotting | ) |
|
Definition at line 248 of file G4HnManager.cc.
249{
250
251
252 for ( auto info : fHnVector ) {
254 }
255}
void SetPlotting(G4int id, G4bool plotting)
◆ SetPlotting() [2/2]
void G4HnManager::SetPlotting |
( |
G4int |
id, |
|
|
G4bool |
plotting |
|
) |
| |
The documentation for this class was generated from the following files: