4 #include "QFiltersData.hh"
29 Info(
"Coincidence flag will be stored in AuxData variable %s",
33 Info(
"Multiplicity will be stored in AuxData variable %s",
fMultName.c_str());
40 Panic(
"No coincidences!");
53 if(!(ev->GetFilters().GetPassed()))
return ev;
55 const QRawEvent& raw = ev->GetRawEvent();
59 bool isSignal = raw.GetPulse().GetIsSignal();
83 ev->AuxData().SetInt(
fMultName, multiplicity,
"save");
86 ev->AuxData().SetInt(
fFlagName, 1,
"save");
88 ev->AuxData().SetInt(
fFlagName, 0,
"save");
#define REGISTER_MODULE(clazz)
A quick module to flag coincidences.
std::vector< unsigned long long > fPreviousTimes
Time of previous events.
unsigned int fCurrentEvent
Event number of current event.
~MFlagCoincidence()
destructor
std::string fFlagName
Name of variable to store in AuxData.
int fnCoincidences
Number of coincidences identified.
int fIteration
What iteration are we on?
std::string fMultName
Name of multiplicity variable in AuxData.
unsigned long long fCurrentTime
Time of current event.
std::multiset< int > fCoincidentEvents
Vector of coincident event numbers.
QEvent * Do(QEvent *ev)
Do method.
std::vector< unsigned int > fPreviousEvents
Event number of previous events.
double fWindow
Time window to be considered coincident (in nanoseconds)
const std::string & GetString(const std::string &parname, const std::string &defVal, bool warnCfg=true) const
Get a string parameter from config file ( see GetDouble() )
void Debug(const char *descr,...) const
Send a debug message (used to debug the module) with printf syntax.
unsigned int GetIteration() const
Get Current sequence iteration.
void Info(const char *descr,...) const
Send an info message (information) with printf syntax.
double GetDouble(const std::string &parname, double defVal, bool warnCfg=true) const
Get a double parameter from config file.
void Panic(const char *descr,...) const
Send a panic message (stops the framework) with printf syntax.
void SetRunAgain(bool b)
Set that the sequence will be reiterated.
unsigned int GetReadNumber() const
return the event number as read by the current reader.
Base class for diana modules.
Diana Reconstruction program.
unsigned long long GetFromStartRunNs() const
retrieve time from start of run in ns