Project
Loading...
Searching...
No Matches
CalibInfoTOF.h
Go to the documentation of this file.
1// Copyright 2019-2020 CERN and copyright holders of ALICE O2.
2// See https://alice-o2.web.cern.ch/copyright for details of the copyright holders.
3// All rights not expressly granted are reserved.
4//
5// This software is distributed under the terms of the GNU General Public
6// License v3 (GPL Version 3), copied verbatim in the file "COPYING".
7//
8// In applying this license CERN does not waive the privileges and immunities
9// granted to it by virtue of its status as an Intergovernmental Organization
10// or submit itself to any jurisdiction.
11
14
15#ifndef ALICEO2_CALIBINFOTOF_H
16#define ALICEO2_CALIBINFOTOF_H
17
18#include "Rtypes.h"
19
20namespace o2
21{
22namespace dataformats
23{
25{
26 public:
27 CalibInfoTOF(int indexTOFCh, int timestamp, float DeltaTimePi, float tot, int mask, int flags = 0) : mTOFChIndex(indexTOFCh), mTimestamp(timestamp), mDeltaTimePi(DeltaTimePi), mTot(tot), mMask(mask), mFlags(flags){};
28 CalibInfoTOF() = default;
29 ~CalibInfoTOF() = default;
30
31 void setTOFChIndex(int index) { mTOFChIndex = index; }
32 int getTOFChIndex() const { return mTOFChIndex; }
33
34 void setTimestamp(int ts) { mTimestamp = ts; }
35 int getTimestamp() const { return mTimestamp; }
36
37 void setDeltaTimePi(float time) { mDeltaTimePi = time; }
38 float getDeltaTimePi() const { return mDeltaTimePi; }
39
40 void setTot(float tot) { mTot = tot; }
41 float getTot() const { return mTot; }
42
43 void setFlags(unsigned char flags) { mFlags = flags; }
44 unsigned char getFlags() const { return mFlags; }
45
46 int getMask() const { return mMask; }
47
48 // for event time maker
49 float tofSignal() const { return mDeltaTimePi; }
50 float tofExpSignalPi() const { return 0.0; }
51 float tofExpSignalKa() const { return 0.0; }
52 float tofExpSignalPr() const { return 0.0; }
53 float tofExpSigmaPi() const { return 500.0; }
54 float tofExpSigmaKa() const { return 500.0; }
55 float tofExpSigmaPr() const { return 500.0; }
56
57 enum Flags {
58 kTPC = BIT(0),
59 kITSTPC = BIT(1),
60 kTPCTRD = BIT(2),
61 kITSTPCTRD = BIT(3),
62 kBelow = BIT(4), // < 0.5 GeV/c
63 kAbove = BIT(5), // > 1.5 GeV/c
64 kNoBC = BIT(6), // no BC in the range
65 kMultiHit = BIT(7) // multi hit cluster
66 };
67
68 private:
69 int mTOFChIndex; // index of the TOF channel
70 int mTimestamp; // timestamp in seconds
71 float mDeltaTimePi; // raw tof time - expected time for pi hypotesis
72 float mTot; // time-over-threshold
73 unsigned char mFlags; // bit mask with quality flags (to be defined)
74 int mMask; // mask for int BC used
75 ClassDefNV(CalibInfoTOF, 2);
76};
77} // namespace dataformats
78} // namespace o2
79#endif
int16_t time
Definition RawEventData.h:4
unsigned char getFlags() const
CalibInfoTOF(int indexTOFCh, int timestamp, float DeltaTimePi, float tot, int mask, int flags=0)
void setFlags(unsigned char flags)
void setDeltaTimePi(float time)
GLuint index
Definition glcorearb.h:781
GLbitfield flags
Definition glcorearb.h:1570
GLint GLuint mask
Definition glcorearb.h:291
a couple of static helper functions to create timestamp values for CCDB queries or override obsolete ...