1 #ifndef ALIMUONBUSSTRUCT_H
2 #define ALIMUONBUSSTRUCT_H
3 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * See cxx source for full Copyright notice */
9 /// \class AliMUONBusStruct
10 /// \brief MUON buspatch structure for tracker
12 /// \author Christian Finck
16 class AliMUONBusStruct : public TObject {
20 virtual ~AliMUONBusStruct ();
21 AliMUONBusStruct(const AliMUONBusStruct& rhs);
22 AliMUONBusStruct& operator=(const AliMUONBusStruct& rhs);
24 Int_t GetTotalLength() const {return fTotalLength;}
25 Int_t GetLength() const {return fLength;}
26 Int_t GetBufSize() const {return fBufSize;}
27 Int_t GetBusPatchId() const {return fBusPatchId;}
28 Int_t GetTriggerWord() const {return fTriggerWord;}
29 UInt_t* GetData() const {return fData;}
30 Int_t GetBlockId() const {return fBlkId;}
31 Int_t GetDspId() const {return fDspId;}
34 Char_t GetParity(Int_t n) const;
35 UShort_t GetManuId(Int_t n) const;
36 Char_t GetChannelId(Int_t n) const;
37 UShort_t GetCharge(Int_t n) const;
38 UInt_t GetData(Int_t n) const;
40 void SetTotalLength(Int_t l) {fTotalLength = l;}
41 void SetLength(Int_t l) {fLength = l;}
42 void SetBusPatchId(Int_t b) {fBusPatchId = b;}
43 void SetTriggerWord(Int_t w) {fTriggerWord = w;}
44 void SetData(UInt_t d, Int_t n) {fData[n] = d;}
45 void SetBlockId(Int_t b) {fBlkId = b;}
46 void SetDspId(Int_t d) {fDspId = d;}
48 void AddData(UInt_t d);
49 void SetAlloc(Int_t size);
51 Bool_t IsSortable() const {return kTRUE;}
52 Int_t Compare(const TObject *obj) const;
53 void Clear(Option_t* opt);
55 Int_t GetHeaderLength() const {return fgkHeaderLength;}
57 Int_t* GetBusPatchHeader() {return &fTotalLength;}
60 Int_t fTotalLength; // total length of buspatch structure
61 Int_t fLength; // length of raw data
62 Int_t fBusPatchId; // bus patch id
63 Int_t fTriggerWord ; // counter trigger word
65 static const Int_t fgkHeaderLength; // header length in word
67 UInt_t* fData; // data
69 Int_t fBufSize; // initial size for data array
71 Int_t fDspId; // Dsp number for monitoring
72 Int_t fBlkId; // block numer for monitoring
74 void ResizeData(Int_t size = 0);
76 ClassDef(AliMUONBusStruct,1) // MUON DDL Tracker