]> git.uio.no Git - u/mrichter/AliRoot.git/blobdiff - MUON/AliMUONRawWriter.h
Fixing compiler warnings
[u/mrichter/AliRoot.git] / MUON / AliMUONRawWriter.h
index 4d58020542a493b775ac7990f758154b913d4bf0..006766f7da4374f18d9e78b57a0bb60e58cf3843 100644 (file)
@@ -5,49 +5,53 @@
 
 /*$Id$*/
 
-/// \ingroup sim
+/// \ingroup base
 /// \class AliMUONRawWriter
 /// \brief Raw data class for trigger and tracker chambers
 ///
 //  Author Christian Finck and Laurent Aphecetche, Subatech
 
 #include <TObject.h>
-#include "AliRawDataHeader.h"
+#include "AliFstream.h"
 
-class AliMUONData;
-class AliMUONDigit;
-class AliMUONDspHeader;
 class AliMUONBlockHeader;
-class AliMUONDarcHeader;
-class AliMUONRegHeader;
-class AliMUONLocalStruct;
-class AliMpExMap;
 class AliMUONBusStruct;
+class AliMUONDarcHeader;
+class AliMUONVDigit;
+class AliMUONDspHeader;
 class AliMUONGlobalTrigger;
+class AliMUONLocalStruct;
+class AliMUONRegHeader;
+class AliMUONVDigitStore;
+class AliMUONVTriggerStore;
 class AliMpDDLStore;
-class AliMUONTriggerCrateStore;
-class TStopwatch;
+class AliMpExMap;
+class AliRawDataHeaderSim;
 
 class AliMUONRawWriter : public TObject 
 {
  public:
-  AliMUONRawWriter(AliMUONData* data); // Constructor
+  AliMUONRawWriter(); // Constructor
   virtual ~AliMUONRawWriter(); // Destructor
     
   // write raw data
-  Int_t Digits2Raw();
-
+  Int_t Digits2Raw(AliMUONVDigitStore* digitStore, AliMUONVTriggerStore* triggerStore);
+  
   void SetScalersNumbers();
 
-protected:
-  AliMUONRawWriter();                  // Default constructor
+  /// Set the header of DDL
+  void SetHeader(AliRawDataHeaderSim& header) {fHeader = &header;}
 
-  // writing raw data
-  Int_t WriteTrackerDDL(Int_t iCh);
-  Int_t WriteTriggerDDL();
-  
 private:
-  Int_t GetBusPatch(const AliMUONDigit& digit) const;
+
+  void Digits2BusPatchMap(const AliMUONVDigitStore& digitStore, AliMpExMap& busPatchMap);
+  void WriteTrackerDDL(AliMpExMap& busPatchMap, Int_t iDDL);
+
+  //void WriteBusPatch(AliMUONLocalBusStruct* busStruct);
+  
+  Int_t WriteTriggerDDL(const AliMUONVTriggerStore& triggerStore, AliFstream* file[2]);
+  
+  Int_t GetBusPatch(const AliMUONVDigit& digit) const;
 
 private:
   /// Not implemented copy constructor
@@ -55,10 +59,9 @@ private:
   /// Not implemented assignment operator
   AliMUONRawWriter& operator=(const AliMUONRawWriter& rhs);
 
-
-  AliMUONData*  fMUONData;           //!< Data container for MUON subsystem 
-  FILE*         fFile[4];            //!< DDL binary file pointer one per 1/2 chamber, 4 for one station
+ static void LocalWordPacking(UInt_t &word, UInt_t locId, UInt_t locDec, 
+                             UInt_t trigY, UInt_t posY, UInt_t posX, 
+                             UInt_t sdevX, UInt_t devX);
 
   AliMUONBlockHeader* fBlockHeader;  //!< DDL block header class pointers
   AliMUONDspHeader*   fDspHeader;    //!< DDL Dsp header class pointers
@@ -67,16 +70,15 @@ private:
   AliMUONLocalStruct* fLocalStruct;  //!< DDL local structure class pointers
 
   AliMpDDLStore*            fDDLStore;     //!< DDL store pointer
-  AliMUONTriggerCrateStore* fCrateManager; //!< Crate array
 
   Bool_t fScalerEvent;               ///< flag to generates scaler event
 
-  AliRawDataHeader    fHeader;           ///< header of DDL
-
+  AliRawDataHeaderSim*    fHeader;           ///< header of DDL
   
-  TStopwatch* fTimers;             //!< time watchers
-  
-  ClassDef(AliMUONRawWriter,2) // MUON cluster reconstructor in ALICE
+  Int_t fBufferSize; //!< size of internal data buffer
+  Int_t* fBuffer; //!< internal data buffer
+
+  ClassDef(AliMUONRawWriter,5) // MUON cluster reconstructor in ALICE
 };
        
 #endif