GRSISort "v4.0.0.5"
An extension of the ROOT analysis Framework
Loading...
Searching...
No Matches
TTriFoil.h
Go to the documentation of this file.
1#ifndef TTRIFOIL_PHASE_H
2#define TTRIFOIL_PHASE_H
3
4/** \addtogroup Detectors
5 * @{
6 */
7
8#include <vector>
9#include <iostream>
10#include <cstdio>
11
12#include "TDetector.h"
13#include "TFragment.h"
14
15class TTriFoil : public TDetector {
16public:
17 TTriFoil();
18 TTriFoil(const TTriFoil& rhs);
19 TTriFoil(TTriFoil&&) noexcept = default;
20 TTriFoil& operator=(const TTriFoil&) = default;
21 TTriFoil& operator=(TTriFoil&&) noexcept = default;
22 ~TTriFoil() override = default;
23
24 std::vector<Short_t> GetWave() { return fTfWave; }
25 bool Beam() const { return fBeam; }
26 int NTBeam() const { return fTBeam.size(); }
27 // int TBeam() const { return TBeam(0); }
28 int TBeam(unsigned int n = 0) const
29 {
30 if(n < fTBeam.size()) {
31 return fTBeam.at(n);
32 }
33 return -1;
34 }
35
36 bool HasWave() const { return !fTfWave.empty(); }
37 time_t GetTimeStamp() const { return fTimestamp; }
38
39#ifndef __CINT__
40 void AddFragment(const std::shared_ptr<const TFragment>&, TChannel*) override; //!<!
41#endif
42 void BuildHits() override {} // no need to build any hits, everything already done in AddFragment
43
44 void Clear(Option_t* opt = "") override; //!<!
45 void Print(Option_t* opt = "") const override; //!<!
46 void Print(std::ostream& out) const override; //!<!
47 void Copy(TObject& rhs) const override;
48
49private:
50 std::vector<Short_t> fTfWave;
51 Long_t fTimestamp{0};
52 bool fBeam{false};
53 std::vector<int> fTBeam;
54
55 /// \cond CLASSIMP
56 ClassDefOverride(TTriFoil, 2) // NOLINT(readability-else-after-return)
57 /// \endcond
58};
59/*! @} */
60#endif
void Clear(Option_t *opt="") override
!
Definition TTriFoil.cxx:8
bool fBeam
Definition TTriFoil.h:52
int NTBeam() const
Definition TTriFoil.h:26
int TBeam(unsigned int n=0) const
Definition TTriFoil.h:28
bool HasWave() const
Definition TTriFoil.h:36
std::vector< int > fTBeam
Definition TTriFoil.h:53
void AddFragment(const std::shared_ptr< const TFragment > &, TChannel *) override
!
Definition TTriFoil.cxx:32
TTriFoil(TTriFoil &&) noexcept=default
void Copy(TObject &rhs) const override
Definition TTriFoil.cxx:18
std::vector< Short_t > fTfWave
Definition TTriFoil.h:50
time_t GetTimeStamp() const
Definition TTriFoil.h:37
void Print(Option_t *opt="") const override
!
Definition TTriFoil.cxx:70
bool Beam() const
Definition TTriFoil.h:25
std::vector< Short_t > GetWave()
Definition TTriFoil.h:24
void BuildHits() override
!
Definition TTriFoil.h:42
Long_t fTimestamp
Definition TTriFoil.h:51