Geant4  10.02.p02
G4ParameterManager Class Reference

#include <G4ParameterManager.hh>

+ Collaboration diagram for G4ParameterManager:

Public Member Functions

 G4ParameterManager (G4bool isMaster=true)
 
virtual ~G4ParameterManager ()
 
template<typename T >
void CreateParameter (const G4String &name, T value, G4MergeMode mergeMode=G4MergeMode::kAddition)
 
template<typename T >
void RegisterParameter (G4Parameter< T > &parameter)
 
template<typename T >
G4Parameter< T > * GetParameter (const G4String &name, G4bool warn=true) const
 
void RegisterParameter (G4VParameter *parameter)
 
G4VParameterGetParameter (const G4String &name, G4bool warn=true) const
 
void Merge ()
 
void Reset ()
 

Static Public Member Functions

static G4ParameterManagerInstance ()
 

Private Attributes

const G4AnalysisManagerState fState
 
std::map< G4String,
G4VParameter * > 
fMap
 
std::vector< G4VParameter * > fParametersToDelete
 

Static Private Attributes

static G4ParameterManagerfgMasterInstance = nullptr
 
static G4ThreadLocal
G4ParameterManager
fgInstance = nullptr
 

Detailed Description

Definition at line 45 of file G4ParameterManager.hh.

Constructor & Destructor Documentation

G4ParameterManager::G4ParameterManager ( G4bool  isMaster = true)

Definition at line 56 of file G4ParameterManager.cc.

References FatalException, fgInstance, fgMasterInstance, and G4Exception().

Referenced by Instance().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

G4ParameterManager::~G4ParameterManager ( )
virtual

Definition at line 74 of file G4ParameterManager.cc.

References fParametersToDelete.

Member Function Documentation

template<typename T >
void G4ParameterManager::CreateParameter ( const G4String name,
value,
G4MergeMode  mergeMode = G4MergeMode::kAddition 
)
template<typename T >
G4Parameter<T>* G4ParameterManager::GetParameter ( const G4String name,
G4bool  warn = true 
) const
G4VParameter * G4ParameterManager::GetParameter ( const G4String name,
G4bool  warn = true 
) const

Definition at line 94 of file G4ParameterManager.cc.

References fMap, G4Exception(), and JustWarning.

+ Here is the call graph for this function:

G4ParameterManager * G4ParameterManager::Instance ( void  )
static

Definition at line 45 of file G4ParameterManager.cc.

References fgInstance, G4ParameterManager(), and G4Threading::IsWorkerThread().

Referenced by B1RunAction::B1RunAction(), B3aRunAction::B3aRunAction(), B3aRunAction::BeginOfRunAction(), B1RunAction::BeginOfRunAction(), B3aRunAction::EndOfRunAction(), and B1RunAction::EndOfRunAction().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void G4ParameterManager::Merge ( )

Definition at line 119 of file G4ParameterManager.cc.

References fgMasterInstance, fMap, G4cout, G4endl, G4Exception(), G4Threading::IsWorkerThread(), JustWarning, second, and G4TemplateAutoLock< M, L, U >::unlock().

Referenced by B3aRunAction::EndOfRunAction(), and B1RunAction::EndOfRunAction().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

template<typename T >
void G4ParameterManager::RegisterParameter ( G4Parameter< T > &  parameter)

Referenced by B1RunAction::B1RunAction(), and B3aRunAction::B3aRunAction().

+ Here is the caller graph for this function:

void G4ParameterManager::RegisterParameter ( G4VParameter parameter)

Definition at line 87 of file G4ParameterManager.cc.

References fMap, and G4VParameter::GetName().

+ Here is the call graph for this function:

void G4ParameterManager::Reset ( )

Definition at line 154 of file G4ParameterManager.cc.

References fMap.

Referenced by B3aRunAction::BeginOfRunAction(), and B1RunAction::BeginOfRunAction().

+ Here is the caller graph for this function:

Member Data Documentation

G4ThreadLocal G4ParameterManager * G4ParameterManager::fgInstance = nullptr
staticprivate

Definition at line 83 of file G4ParameterManager.hh.

Referenced by G4ParameterManager(), and Instance().

G4ParameterManager * G4ParameterManager::fgMasterInstance = nullptr
staticprivate

Definition at line 82 of file G4ParameterManager.hh.

Referenced by G4ParameterManager(), and Merge().

std::map<G4String, G4VParameter*> G4ParameterManager::fMap
private

Definition at line 87 of file G4ParameterManager.hh.

Referenced by GetParameter(), Merge(), RegisterParameter(), and Reset().

std::vector<G4VParameter*> G4ParameterManager::fParametersToDelete
private

Definition at line 88 of file G4ParameterManager.hh.

Referenced by ~G4ParameterManager().

const G4AnalysisManagerState G4ParameterManager::fState
private

Definition at line 86 of file G4ParameterManager.hh.


The documentation for this class was generated from the following files: