04fa961a |
1 | #ifndef ALIRAWREADERFILE_H |
2 | #define ALIRAWREADERFILE_H |
3 | /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. * |
4 | * See cxx source for full Copyright notice */ |
5 | |
6 | #include "AliRawReader.h" |
cfe26801 |
7 | #ifdef __CINT__ |
8 | class fstream; |
9 | #else |
04fa961a |
10 | #include <Riostream.h> |
cfe26801 |
11 | #endif |
04fa961a |
12 | #include <TString.h> |
13 | |
14 | |
15 | class AliRawReaderFile: public AliRawReader { |
16 | public : |
17 | AliRawReaderFile(const char* fileName, Bool_t addNumber = kTRUE); |
42d20574 |
18 | AliRawReaderFile(const AliRawReaderFile& rawReader); |
19 | AliRawReaderFile& operator = (const AliRawReaderFile& rawReader); |
04fa961a |
20 | virtual ~AliRawReaderFile(); |
21 | |
42d20574 |
22 | virtual UInt_t GetType() const {return 0;}; |
23 | virtual UInt_t GetRunNumber() const {return 0;}; |
24 | virtual const UInt_t* GetEventId() const {return 0;}; |
25 | virtual const UInt_t* GetTriggerPattern() const {return 0;}; |
26 | virtual const UInt_t* GetDetectorPattern() const {return 0;}; |
27 | virtual const UInt_t* GetAttributes() const {return 0;}; |
28 | virtual UInt_t GetGDCId() const {return 0;}; |
04fa961a |
29 | |
30 | |
31 | virtual Bool_t ReadMiniHeader(); |
32 | virtual Bool_t ReadNextData(UChar_t*& data); |
33 | |
34 | virtual Bool_t Reset(); |
35 | |
36 | protected : |
37 | Bool_t OpenNextFile(); |
38 | |
39 | virtual Bool_t ReadNext(UChar_t* data, Int_t size); |
40 | |
41 | TString fFileName; // name of input files |
42 | Int_t fFileNumber; // number of current input file |
43 | fstream* fStream; // stream of raw digits |
44 | UChar_t* fBuffer; // buffer for payload |
45 | Int_t fBufferSize; // size of fBuffer in bytes |
46 | |
47 | ClassDef(AliRawReaderFile, 0) // class for reading raw digits from a file |
48 | }; |
49 | |
50 | #endif |