 |
Belle II Software
release-05-02-19
|
Go to the documentation of this file.
28 explicit ProcHandler(
unsigned int nWorkerProc,
bool markChildrenAsLocal =
false);
static bool isWorkerProcess()
Return true if the process is a worker process.
unsigned int m_numWorkerProcesses
Number of worker processes controlled by this ProcHandler.
bool waitForAllProcesses()
Wait until all forked processes handled by this ProcHandler terminate.
void startInputProcess()
Fork and initialize an input process.
bool m_markChildrenAsLocal
Anormal termination of child will not stop parent, waitForAllProcesses() returns status.
ProcHandler(unsigned int nWorkerProc, bool markChildrenAsLocal=false)
Constructor.
static bool isOutputProcess()
Return true if the process is an output process.
std::set< int > m_processList
PIDs of processes controlled by this ProcHandler.
static std::string getProcessName()
Get a name for this process.
static std::set< int > globalProcessList()
Return list of all PIDs (from all ProcHandler instances).
void startOutputProcess()
There is no real output process, but marks current process as output.
~ProcHandler()
Destructor.
Abstract base class for different kinds of events.
void startWorkerProcesses()
Fork and initialize worker processes.
A class to manage processes for parallel processing.
static int EvtProcID()
Return ID of the current process.
std::set< int > processList() const
Return list of PIDs managed by this ProcHandler instance.
static void setProcessID(int processID)
Set the process ID of this process.
static bool isInputProcess()
Return true if the process is an input process.
bool startProc(std::set< int > *processList, const std::string &procType, int id)
Start a new process, adding its PID to processList, and setting s_processID = id.
static bool parallelProcessingUsed()
Returns true if multiple processes have been spawned, false in single-core mode.
static int numEventProcesses()
Return number of worker processes (configured value, not current)