BmnRoot
Loading...
Searching...
No Matches
BmnSsdSignal.h
Go to the documentation of this file.
1
7#ifndef BMNSSDSIGNAL_H
8#define BMNSSDSIGNAL_H 1
9
10#include "TObject.h"
11#include "BmnMatch.h"
12
13
27class BmnSsdSignal : public TObject {
28
29 public:
30
38 BmnSsdSignal(Double_t time = 0., Double_t charge = 0.,
39 Int_t index = 0, Int_t entry = -1, Int_t file = -1);
40
41
43 virtual ~BmnSsdSignal();
44
45
52 void AddLink(Double_t charge, Int_t index,
53 Int_t entry = -1, Int_t file = -1) {
54 fMatch.AddLink(charge, index, entry, file);
55 }
56
57
61 Double_t GetCharge() const { return fMatch.GetTotalWeight(); }
62
63
67 const BmnMatch& GetMatch() const { return fMatch; }
68
69
73 Double_t GetTime() const { return fTime; }
74
75
79 void SetTime(Double_t time) { fTime = time; }
80
81
86 bool operator < (const BmnSsdSignal& otherSignal) const {
87 return ( fTime < otherSignal.GetTime() );
88 }
89
90
95 struct Before {
96 bool operator () (BmnSsdSignal* signal1, BmnSsdSignal* signal2) {
97 return ( signal1->GetTime() < signal2->GetTime() );
98 }
99 };
100
101 private:
102
103 Double_t fTime;
104 BmnMatch fMatch;
105
106 ClassDef(BmnSsdSignal, 1);
107};
108
109#endif /* BMNSSDSIGNAL_H */
Double_t GetTotalWeight() const
Definition BmnMatch.h:41
void AddLink(const BmnMatch &match)
Definition BmnMatch.cxx:43
Data class for an analog signal in the SSD.
void SetTime(Double_t time)
bool operator<(const BmnSsdSignal &otherSignal) const
const BmnMatch & GetMatch() const
void AddLink(Double_t charge, Int_t index, Int_t entry=-1, Int_t file=-1)
virtual ~BmnSsdSignal()
Double_t GetTime() const
Double_t GetCharge() const
bool operator()(BmnSsdSignal *signal1, BmnSsdSignal *signal2)