TraceV3D_ROOT.h
Go to the documentation of this file.
1 #ifndef _TraceV3D_ROOT_h_
2 #define _TraceV3D_ROOT_h_
3 
4 #include <io/EventIO.h>
5 #ifndef __CINT__
6 # include <utl/Trace.h>
7 #endif
8 #include <Rtypes.h>
9 #include <TVector3.h>
10 #include <vector>
11 
12 
13 namespace io {
14 
23  class TraceV3D_ROOT {
24  public:
26 #ifndef __CINT__
27  TraceV3D_ROOT(const utl::TraceV3D& trace);
28  void operator>>(utl::TraceV3D& trace) const;
29  explicit operator bool() const { return !fArray.empty(); }
30  utl::TraceV3D Convert() const { utl::TraceV3D t; *this >> t; return t; }
31 
32  static TVector3 Convert(const utl::TraceV3D::ValueType& x) { return TVector3(x[0], x[1], x[2]); }
33 
34  static
36  Convert(const TVector3& x)
37  {
39  for (unsigned int i = 0; i < 3; ++i)
40  t[i] = x[i];
41  return t;
42  }
43 #endif
44 
45  double fBinning = 0;
46  unsigned int fStart = 0;
47  unsigned int fStop = 0;
48  std::vector<TVector3> fArray;
49 
51 
52  };
53 
54 }
55 
56 
57 #endif
std::vector< TVector3 > fArray
Definition: TraceV3D_ROOT.h:48
void operator>>(utl::TraceV3D &trace) const
static utl::TraceV3D::ValueType Convert(const TVector3 &x)
Definition: TraceV3D_ROOT.h:36
utl::TraceV3D Convert() const
Definition: TraceV3D_ROOT.h:30
static TVector3 Convert(const utl::TraceV3D::ValueType &x)
Definition: TraceV3D_ROOT.h:32
ClassDefNV(TraceV3D_ROOT, DONT_CHANGE_THIS_NUMBER)
unsigned int fStop
Definition: TraceV3D_ROOT.h:47
#define DONT_CHANGE_THIS_NUMBER
Definition: EventIO.h:21
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
ROOT streamer for TraceV3D.
Definition: TraceV3D_ROOT.h:23
T ValueType
Definition: Trace.h:57
unsigned int fStart
Definition: TraceV3D_ROOT.h:46

, generated on Tue Sep 26 2023.