Now uses the simplified interface of RawStreamTracker to loop over raw data
[u/mrichter/AliRoot.git] / MUON / AliMUONRawStreamTracker.h
CommitLineData
c0751163 1#ifndef ALIMUONRAWSTREAMTRACKER_H
2#define ALIMUONRAWSTREAMTRACKER_H
3/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * See cxx source for full Copyright notice */
5
6/*$Id$*/
7
be68bd50 8/// \ingroup raw
c0751163 9/// \class AliMUONRawStreamTracker
10/// \brief Class for reading MUON raw digits
11///
c4ee792d 12// Author: Christian Finck
c0751163 13
14#include <TObject.h>
313a427d 15#include "AliMUONPayloadTracker.h"
c0751163 16
17class AliRawReader;
18class AliMUONDDLTracker;
313a427d 19
c0751163 20
21class AliMUONRawStreamTracker: public TObject {
22 public :
23 AliMUONRawStreamTracker();
24 AliMUONRawStreamTracker(AliRawReader* rawReader);
c0751163 25 virtual ~AliMUONRawStreamTracker();
26
27 virtual Bool_t Next();
28 virtual Bool_t NextDDL();
c0751163 29
71a2d3aa 30 /// Return maximum number of DDL in DATE file
c0751163 31 Int_t GetMaxDDL() const {return fMaxDDL;}
71a2d3aa 32 /// Return maximum number of block per DDL in DATE file
313a427d 33 Int_t GetMaxBlock() const {return fPayload->GetMaxBlock();}
71a2d3aa 34 /// Return maximum number of Dsp per block in DATE file
313a427d 35 Int_t GetMaxDsp() const {return fPayload->GetMaxDsp();}
71a2d3aa 36 /// Return maximum number of Buspatch per Dsp in DATE file
313a427d 37 Int_t GetMaxBus() const {return fPayload->GetMaxBus();}
c0751163 38
39 // check input before assigment
40 void SetMaxDDL(Int_t ddl);
41 void SetMaxBlock(Int_t blk);
42
71a2d3aa 43 /// Set maximum number of Dsp per block in DATE file
44 /// does not check, done via BusPatchManager
313a427d 45 void SetMaxDsp(Int_t dsp) {fPayload->SetMaxDsp(dsp);}
71a2d3aa 46 /// Set maximum number of Buspatch per Dsp in DATE file
47 /// does not check, done via BusPatchManager
313a427d 48 void SetMaxBus(Int_t bus) {fPayload->SetMaxBus(bus);}
c0751163 49
71a2d3aa 50 /// Set object for reading the raw data
c0751163 51 void SetReader(AliRawReader* rawReader) {fRawReader = rawReader;}
52
54e01c1c 53 /// Return pointer for DDL
54 AliMUONDDLTracker* GetDDLTracker() const {return fPayload->GetDDLTracker();}
55
56 /// Return pointer for payload
57 AliMUONPayloadTracker* GetPayLoad() const {return fPayload;}
58
71a2d3aa 59 /// Return number of DDL
54e01c1c 60 Int_t GetDDL() const {return fDDL - 1;}
c0751163 61
9f5dcca3 62 private :
71a2d3aa 63 /// Not implemented
64 AliMUONRawStreamTracker(const AliMUONRawStreamTracker& stream);
65 /// Not implemented
66 AliMUONRawStreamTracker& operator = (const AliMUONRawStreamTracker& stream);
c0751163 67
829425a5 68 AliRawReader* fRawReader; ///< object for reading the raw data
c0751163 69
829425a5 70 Int_t fDDL; ///< number of DDL
71 Int_t fBusPatchId; ///< entry of buspatch structure
72 Int_t fDspId; ///< entry of Dsp header
73 Int_t fBlkId; ///< entry of Block header
c0751163 74
829425a5 75 Bool_t fNextDDL; ///< flag for next DDL to be read
c0751163 76
313a427d 77 Int_t fMaxDDL; ///< maximum number of DDL in DATE file
c0751163 78
313a427d 79 AliMUONPayloadTracker* fPayload; ///< pointer to payload decoder
c0751163 80
313a427d 81 ClassDef(AliMUONRawStreamTracker, 2) // base class for reading MUON raw digits
c0751163 82};
83
84#endif