]> git.uio.no Git - u/mrichter/AliRoot.git/blob - FMD/AliFMDRawReader.h
Correct raw data reconstruction in case of trigger
[u/mrichter/AliRoot.git] / FMD / AliFMDRawReader.h
1 #ifndef ALIFMDRAWREADER_H
2 #define ALIFMDRAWREADER_H
3 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights
4  * reserved. 
5  *
6  * Latest changes by Christian Holm Christensen <cholm@nbi.dk>
7  *
8  * See cxx source for full Copyright notice                               
9  */
10 /* $Id$ */
11 /** @file    AliFMDRawReader.h
12     @author  Christian Holm Christensen <cholm@nbi.dk>
13     @date    Mon Mar 27 12:45:23 2006
14     @brief   Class to read raw data 
15 */
16 //____________________________________________________________________
17 // 
18 // Class to read ADC values from a AliRawReader object. 
19 // Note, that it uses an ALTRO reader, which is wrong. 
20 // Perhaps we need to implement it our selves
21 // 
22 #ifndef ROOT_TTask
23 # include <TTask.h>
24 #endif
25
26 //____________________________________________________________________
27 class AliRawReader;
28 class TTree;
29 class TClonesArray;
30
31
32 //____________________________________________________________________
33 /** @brief Class to read ALTRO formated raw data from an AliRawReader
34     object. 
35     @code 
36     AliRawReader*    reader    = new AliRawReaderFile(0);
37     AliFMDRawReader* fmdReader = new AliFMDRawReader(reader);
38     TClonesArray*    array     = new TClonesArray("AliFMDDigit");
39     fmdReader->ReadAdcs(array);
40     @endcode 
41     @ingroup FMD_rec
42 */
43 class AliFMDRawReader : public TTask 
44 {
45 public:
46   /** CTOR 
47       @param reader Raw reader
48       @param array  Output tree */
49   AliFMDRawReader(AliRawReader* reader, TTree* array);
50   /** DTOR */
51   virtual ~AliFMDRawReader() {}
52   /** Read in, and store in output tree 
53       @param option Not used */
54   virtual void   Exec(Option_t* option="");
55   /** Read ADC's into a TClonesArray of AliFMDDigit objects. 
56       @param array Array to read into 
57       @return @c true on success */
58   virtual Bool_t ReadAdcs(TClonesArray* array);
59 protected:
60   TTree*        fTree;       //! Pointer to tree to read into 
61   AliRawReader* fReader;     //! Pointer to raw reader 
62   UShort_t      fSampleRate; // The sample rate (if 0, inferred from data)
63   ClassDef(AliFMDRawReader, 0) // Read FMD raw data into a cache 
64 };
65
66 #endif
67 //____________________________________________________________________
68 //
69 // Local Variables:
70 //   mode: C++
71 // End:
72 //
73 // EOF
74 //