]> git.uio.no Git - u/mrichter/AliRoot.git/blame_incremental - T0/AliT0RawReader.h
coding violation fixes
[u/mrichter/AliRoot.git] / T0 / AliT0RawReader.h
... / ...
CommitLineData
1#ifndef ALIT0RAWREADER_H
2#define ALIT0RAWREADER_H
3
4#include <TTask.h>
5#include <Riostream.h>
6#include "AliRawReader.h"
7#include "AliT0Parameters.h"
8
9class AliT0RawReader : public TTask {
10 public :
11
12 AliT0RawReader(AliRawReader *rawReader,Bool_t isOnline = kFALSE) ;
13
14 virtual ~AliT0RawReader();
15 AliT0RawReader(const AliT0RawReader& o): TTask(o),
16 fRawReader(0),
17 fData(NULL),
18 fPosition(0),
19 fParam(0),
20 fIsOnline(kFALSE)
21 {}
22
23 AliT0RawReader& operator=(const AliT0RawReader&) { return *this; }
24
25
26 Bool_t Next(); //read next raw digit
27 Int_t GetPosition();
28 UInt_t GetNextWord();
29 Int_t GetData(Int_t channel, Int_t hit) {return fAllData[channel][hit];}
30 // void SetNumberOfTRM(Int_t trm=2) {fNTRM=trm;}
31
32 enum ET0RawReaderError {
33 kIncorrectDataSize = 1,
34 kWrongDRMHeader = 2,
35 kWrongDRMTrailer = 3,
36 kWrongTRMHeader = 4,
37 kWrongTRMTrailer = 5,
38 kWrongChain0Header = 6,
39 kWrongChain0Trailer = 7,
40 kWrongChain1Header = 8,
41 kWrongChain1Trailer = 9,
42 kIncorrectLUT = 10
43 };
44
45 Bool_t IsOnlineMode () {return fIsOnline;}
46
47 protected :
48
49 AliRawReader* fRawReader; // object for reading the raw data
50 UChar_t* fData; // raw data
51 Int_t fPosition; // current (32 bit) position in fData
52 AliT0Parameters *fParam;
53// Int_t fNTRM; //number of TRMs, 1 - testbeam; 2 - simulation
54 Bool_t fIsOnline;
55
56 Int_t fAllData[110][5];
57
58 ClassDef(AliT0RawReader,2) //class for reading T0 Raw data
59};
60
61typedef AliT0RawReader AliSTARTRawReader; // for backward compatibility
62
63#endif