PixelTriggerData.cc
Go to the documentation of this file.
1 #include <fevt/PixelTriggerData.h>
2 #include <utl/ErrorLogger.h>
3 #include <utl/AugerException.h>
4 #include <utl/Trace.h>
5 
6 #include <string>
7 using namespace std;
8 
9 using namespace utl;
10 using namespace fevt;
11 
12 
13 PixelTriggerData::PixelTriggerData() :
14  fThreshold(0),
15  fPreviousThreshold(0),
16  fThresholdChanged(false),
17  fMean(0),
18  fVariance(0),
19  fRate(0) {
20 }
21 
22 
24 
25  if (HasFLTTrace()) {
26  return *fFLTTrace;
27  }
28 
29  string err = "FLT trace not available!";
30  ERROR(err);
31  throw (NonExistentComponentException(err));
32 }
33 
34 
36 
37  if (HasFLTTrace()) {
38  return *fFLTTrace;
39  }
40 
41  string err = "FLT trace not available!";
42  ERROR(err);
43  throw (NonExistentComponentException(err));
44 }
45 
47 
48  if (HasFLTTrace()) {
49  ERROR("Existing FLT trace will get overwritten ! ");
50  }
51 
52  fFLTTrace = new TraceB(flt);
53 }
54 
56  if (HasFLTTrace())
57  for (TraceB::ConstIterator it = (*fFLTTrace).Begin(); it!=(*fFLTTrace).End(); ++it) {
58  if (*it) return true;
59  }
60  return false;
61 }
62 
63 
64 // Configure (x)emacs for this file ...
65 // Local Variables:
66 // mode: c++
67 // compile-command: "make -C .. FEvent/PixelTriggerData.o -k"
68 // End:
Base class for exceptions trying to access non-existing components.
std::vector< T >::const_iterator ConstIterator
Definition: Trace.h:60
Trace< char > TraceB
Definition: Trace-fwd.h:28
void MakeFLTTrace(const utl::TraceB &flt)
Template class for a FADC data or calibrated data container. Use the typedefs (TraceD, TraceI, etc.) defined in Trace-fwd.h.
Definition: Trace-fwd.h:19
utl::TraceB & GetFLTTrace()
#define ERROR(message)
Macro for logging error messages.
Definition: ErrorLogger.h:165
utl::ShadowPtr< utl::TraceB > fFLTTrace

, generated on Tue Sep 26 2023.