#include <FastSimulationBase.h>
|
Gaudi::Property< std::string > | m_regionName {this, "RegionName", ""} |
| The region to which this fast sim is assigned. More...
|
|
Gaudi::Property< bool > | m_noRegions {this, "NoRegions", false} |
| This Fast Simulation has no regions associated with it. More...
|
|
- Todo:
- TODO needs class documentation
Definition at line 27 of file FastSimulationBase.h.
◆ FastSimulationBase()
FastSimulationBase::FastSimulationBase |
( |
const std::string & |
type, |
|
|
const std::string & |
name, |
|
|
const IInterface * |
parent |
|
) |
| |
◆ ~FastSimulationBase()
FastSimulationBase::~FastSimulationBase |
( |
| ) |
|
|
virtual |
◆ BeginOfAthenaEvent()
virtual StatusCode FastSimulationBase::BeginOfAthenaEvent |
( |
| ) |
|
|
inlineoverridevirtual |
Begin of an athena event - do anything that needs to be done at the beginning of each athena event.
Reimplemented in FastCaloSimTool.
Definition at line 42 of file FastSimulationBase.h.
42 {
return StatusCode::SUCCESS; }
◆ deleteFastSimModel()
void FastSimulationBase::deleteFastSimModel |
( |
| ) |
|
|
private |
Delete the current model.
Definition at line 78 of file FastSimulationBase.cxx.
80 #ifdef G4MULTITHREADED
81 for(
auto& threadMapPair : m_fastsimmodelThreadMap)
83 auto fastSimModel = threadMapPair.second;
87 m_fastsimmodelThreadMap.clear();
◆ EndOfAthenaEvent()
virtual StatusCode FastSimulationBase::EndOfAthenaEvent |
( |
| ) |
|
|
inlineoverridevirtual |
End of an athena event - do any tidying up required at the end of each athena event.
Reimplemented in FastCaloSimTool.
Definition at line 45 of file FastSimulationBase.h.
45 {
return StatusCode::SUCCESS; }
◆ getFastSimModel()
G4VFastSimulationModel * FastSimulationBase::getFastSimModel |
( |
| ) |
|
|
protected |
Retrieve the current Fast Simulation Model.
In MT, this means the thread-local Fast Simulation Model. Otherwise, it is simply the single Fast Simulation Model.
Definition at line 52 of file FastSimulationBase.cxx.
54 #ifdef G4MULTITHREADED
56 const auto tid = std::this_thread::get_id();
58 auto fastsimmodelPair = m_fastsimmodelThreadMap.find(tid);
59 if(fastsimmodelPair == m_fastsimmodelThreadMap.end())
return nullptr;
60 return fastsimmodelPair->second;
◆ getRegion()
G4Region * FastSimulationBase::getRegion |
( |
| ) |
const |
|
protected |
◆ initializeFastSim()
StatusCode FastSimulationBase::initializeFastSim |
( |
| ) |
|
|
override |
Construct and setup the fast simulation model.
This method invokes the makeFastSimModel of the derived concrete tool type and assigns the configured regions. Errors are reported if regions are missing. In multi-threading jobs, this method is called once per worker thread.
Definition at line 32 of file FastSimulationBase.cxx.
37 ATH_MSG_ERROR(
"Trying to create a Fast Simulation Model which already exists!");
38 return StatusCode::FAILURE;
42 auto* fastsimmodel = makeFastSimModel();
49 return StatusCode::SUCCESS;
◆ setFastSimModel()
void FastSimulationBase::setFastSimModel |
( |
G4VFastSimulationModel * |
fastsimmodel | ) |
|
|
private |
Set the current model. In hive, this gets assigned as the thread-local model.
Definition at line 66 of file FastSimulationBase.cxx.
68 #ifdef G4MULTITHREADED
70 const auto tid = std::this_thread::get_id();
71 ATH_MSG_DEBUG(
"Creating and registering FastSimModel " << fastsimmodel <<
" in thread " << tid);
72 m_fastsimmodelThreadMap.insert( std::make_pair(tid, fastsimmodel) );
◆ m_FastSimModel
G4VFastSimulationModel* FastSimulationBase::m_FastSimModel {} |
|
private |
◆ m_noRegions
Gaudi::Property<bool> FastSimulationBase::m_noRegions {this, "NoRegions", false} |
|
protected |
◆ m_regionName
Gaudi::Property<std::string> FastSimulationBase::m_regionName {this, "RegionName", ""} |
|
protected |
The documentation for this class was generated from the following files: