]>
Commit | Line | Data |
---|---|---|
1 | #ifndef ALIMUONDSPHEADER_H | |
2 | #define ALIMUONDSPHEADER_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 | ||
8 | /// \ingroup raw | |
9 | /// \class AliMUONDspHeader | |
10 | /// \brief MUON DSP header for tracker event | |
11 | /// | |
12 | // Author Christian Finck | |
13 | ||
14 | #include <TObject.h> | |
15 | #include <TClonesArray.h> | |
16 | ||
17 | class AliMUONBusStruct; | |
18 | ||
19 | class AliMUONDspHeader : public TObject { | |
20 | ||
21 | public: | |
22 | AliMUONDspHeader(); | |
23 | AliMUONDspHeader(const AliMUONDspHeader& event); | |
24 | AliMUONDspHeader& operator=(const AliMUONDspHeader& event); | |
25 | ||
26 | virtual ~AliMUONDspHeader(); | |
27 | ||
28 | // DSP header | |
29 | /// Return Data key word for FRT header | |
30 | Int_t GetDataKey() const {return fDataKey;} | |
31 | /// Return total length of block structure | |
32 | Int_t GetTotalLength() const {return fTotalLength;} | |
33 | /// Return length of raw data | |
34 | Int_t GetLength() const {return fLength;} | |
35 | /// Return Dsp id | |
36 | Int_t GetDspId() const {return fDspId;} | |
37 | /// Return L1 accept in Block Structure (CRT) | |
38 | Int_t GetBlkL1ATrigger() const {return fBlkL1ATrigger;} | |
39 | /// Return Mini Event Id in bunch crossing | |
40 | Int_t GetMiniEventId() const {return fMiniEventId;} | |
41 | /// Return Number of L1 accept in DSP Structure (FRT) | |
42 | Int_t GetL1ATrigger() const {return fL1ATrigger;} | |
43 | /// Return Number of L1 reject in DSP Structure (FRT) | |
44 | Int_t GetL1RTrigger() const {return fL1RTrigger;} | |
45 | /// Return padding dummy word for 64 bits transfer | |
46 | UInt_t GetPaddingWord() const {return fPaddingWord;} | |
47 | /// Return Error word | |
48 | Int_t GetErrorWord() const {return fErrorWord;} | |
49 | ||
50 | /// Return header length | |
51 | Int_t GetHeaderLength() const {return fgkHeaderLength;} | |
52 | /// Return default data key word for FRT header | |
53 | UInt_t GetDefaultDataKey() const {return fgkDefaultDataKey;} | |
54 | /// Return default padding word value | |
55 | UInt_t GetDefaultPaddingWord() const {return fgkDefaultPaddingWord;} | |
56 | ||
57 | /// Set Data key word for FRT header | |
58 | void SetDataKey(Int_t d) {fDataKey = d;} | |
59 | /// Set total length of block structure | |
60 | void SetTotalLength(Int_t l) {fTotalLength = l;} | |
61 | /// Set length of raw data | |
62 | void SetLength(Int_t l) {fLength = l;} | |
63 | /// Set Dsp id | |
64 | void SetDspId(Int_t d) {fDspId = d;} | |
65 | /// Set L1 accept in Block Structure (CRT) | |
66 | void SetBlkL1ATrigger(Int_t l1) {fBlkL1ATrigger = l1;} | |
67 | /// Set Mini Event Id in bunch crossing | |
68 | void SetMiniEventId(Int_t id) {fMiniEventId = id;} | |
69 | /// Set Number of L1 accept in DSP Structure (FRT) | |
70 | void SetL1ATrigger(Int_t l1a) {fL1ATrigger = l1a;} | |
71 | /// Set Number of L1 reject in DSP Structure (FRT) | |
72 | void SetL1RTrigger(Int_t l1r) {fL1RTrigger = l1r;} | |
73 | /// Set padding dummy word for 64 bits transfer | |
74 | void SetPaddingWord(UInt_t w) {fPaddingWord = w;} | |
75 | /// Set Error word | |
76 | void SetErrorWord(Int_t w) {fErrorWord = w;} | |
77 | ||
78 | /// Return header | |
79 | Int_t* GetHeader() {return &fDataKey;} | |
80 | ||
81 | void AddBusPatch(const AliMUONBusStruct& busPatch); | |
82 | ||
83 | /// get TClonesArray | |
84 | TClonesArray* GetBusPatchArray() const {return fBusPatchArray;} | |
85 | ||
86 | /// get entries | |
87 | Int_t GetBusPatchEntries() const {return fBusPatchArray->GetEntriesFast();} | |
88 | ||
89 | /// get entry | |
90 | AliMUONBusStruct* GetBusPatchEntry(Int_t i) const { | |
91 | return (AliMUONBusStruct*)fBusPatchArray->At(i);} | |
92 | ||
93 | // clear | |
94 | void Clear(Option_t* opt); | |
95 | ||
96 | // print out | |
97 | void Print(Option_t* /*opt*/) const; | |
98 | ||
99 | private: | |
100 | ||
101 | // Dsp header | |
102 | Int_t fDataKey; ///< Data key word for FRT header | |
103 | Int_t fTotalLength; ///< total length of block structure | |
104 | Int_t fLength; ///< length of raw data | |
105 | Int_t fDspId; ///< Dsp id | |
106 | Int_t fBlkL1ATrigger; ///< L1 accept in Block Structure (CRT) | |
107 | Int_t fMiniEventId; ///< Mini Event Id in bunch crossing | |
108 | Int_t fL1ATrigger; ///< Number of L1 accept in DSP Structure (FRT) | |
109 | Int_t fL1RTrigger; ///< Number of L1 reject in DSP Structure (FRT) | |
110 | Int_t fPaddingWord; ///< padding dummy word for 64 bits transfer | |
111 | Int_t fErrorWord; ///< Error word | |
112 | ||
113 | static const Int_t fgkHeaderLength; ///< header length | |
114 | static const UInt_t fgkDefaultDataKey; ///< default data key word for FRT header | |
115 | static const UInt_t fgkDefaultPaddingWord; ///< default padding word value | |
116 | ||
117 | TClonesArray* fBusPatchArray; ///< array of buspatch structure | |
118 | ||
119 | ClassDef(AliMUONDspHeader,2) // MUON Dsp header for Tracker event | |
120 | }; | |
121 | #endif |