SimG4Core
Application
src
RunAction.cc
Go to the documentation of this file.
1
#include "
SimG4Core/Application/interface/RunAction.h
"
2
#include "
SimG4Core/Application/interface/SimRunInterface.h
"
3
4
#include "
SimG4Core/Notification/interface/BeginOfRun.h
"
5
#include "
SimG4Core/Notification/interface/EndOfRun.h
"
6
7
#include "
FWCore/MessageLogger/interface/MessageLogger.h
"
8
9
#include <iostream>
10
#include <fstream>
11
12
RunAction::RunAction
(
const
edm::ParameterSet
&
p
,
SimRunInterface
*
rm
,
bool
)
13
: m_runInterface(
rm
), m_stopFile(
p
.getParameter<
std
::
string
>(
"StopFile"
)) {}
14
15
RunAction::~RunAction
() {}
16
17
void
RunAction::BeginOfRunAction
(
const
G4Run* aRun) {
18
if
(!
m_stopFile
.empty() && std::ifstream(
m_stopFile
.c_str())) {
19
edm::LogWarning
(
"SimG4CoreApplication"
) <<
"RunAction::BeginOfRunAction: termination signal received"
;
20
m_runInterface
->
abortRun
(
true
);
21
}
22
BeginOfRun
r
(aRun);
23
m_beginOfRunSignal
(&
r
);
24
}
25
26
void
RunAction::EndOfRunAction
(
const
G4Run* aRun) {
27
EndOfRun
r
(aRun);
28
m_endOfRunSignal
(&
r
);
29
}
RunAction.h
MessageLogger.h
SimRunInterface::abortRun
void abortRun(bool softAbort)
Definition:
SimRunInterface.cc:90
AlCaHLTBitMon_ParallelJobs.p
p
Definition:
AlCaHLTBitMon_ParallelJobs.py:153
RunAction::m_beginOfRunSignal
SimActivityRegistry::BeginOfRunSignal m_beginOfRunSignal
Definition:
RunAction.h:23
BeginOfRun.h
submit.rm
rm
Definition:
submit.py:77
RunAction::m_runInterface
SimRunInterface * m_runInterface
Definition:
RunAction.h:27
AlCaHLTBitMon_QueryRunRegistry.string
string
Definition:
AlCaHLTBitMon_QueryRunRegistry.py:256
edm::LogWarning
Definition:
MessageLogger.h:141
edm::ParameterSet
Definition:
ParameterSet.h:36
BeginOfRun
Definition:
BeginOfRun.h:6
EndOfRun
Definition:
EndOfRun.h:6
alignCSCRings.r
r
Definition:
alignCSCRings.py:93
EndOfRun.h
RunAction::m_endOfRunSignal
SimActivityRegistry::EndOfRunSignal m_endOfRunSignal
Definition:
RunAction.h:24
std
Definition:
JetResolutionObject.h:76
RunAction::~RunAction
~RunAction() override
Definition:
RunAction.cc:15
SimRunInterface.h
RunAction::EndOfRunAction
void EndOfRunAction(const G4Run *aRun) override
Definition:
RunAction.cc:26
RunAction::RunAction
RunAction(const edm::ParameterSet &ps, SimRunInterface *, bool master)
Definition:
RunAction.cc:12
RunAction::m_stopFile
std::string m_stopFile
Definition:
RunAction.h:28
RunAction::BeginOfRunAction
void BeginOfRunAction(const G4Run *aRun) override
Definition:
RunAction.cc:17
SimRunInterface
Definition:
SimRunInterface.h:18
Generated for CMSSW Reference Manual by
1.8.16