]> git.uio.no Git - u/mrichter/AliRoot.git/blame - MUON/AliMUONTrackerRawDataMaker.h
Fixews for new AMORE DA release (agreed with Sylvain and Barth)
[u/mrichter/AliRoot.git] / MUON / AliMUONTrackerRawDataMaker.h
CommitLineData
0145e89a 1#ifndef ALIMUONTRACKERRAWDATAMAKER_H
2#define ALIMUONTRACKERRAWDATAMAKER_H
3
4/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
5* See cxx source for full Copyright notice */
6
7// $Id$
8
4ef00a18 9/// \ingroup rec
0145e89a 10/// \class AliMUONTrackerRawDataMaker
8741815f 11/// \brief Creator of raw AliMUONVTrackerData from AliRawReader
0145e89a 12///
13// Author Laurent Aphecetche, Subatech
14
15#ifndef ALIMUONVTRACKERDATAMAKER_H
16# include "AliMUONVTrackerDataMaker.h"
17#endif
18#ifndef ROOT_TString
19# include "TString.h"
20#endif
21
22class AliRawReader;
0145e89a 23class AliMUONVStore;
8741815f 24class AliMUONVTrackerData;
0145e89a 25
26class AliMUONTrackerRawDataMaker : public AliMUONVTrackerDataMaker
27{
28public:
515cc5b5 29 AliMUONTrackerRawDataMaker(TRootIOCtor* ioCtor);
30
31 AliMUONTrackerRawDataMaker(Int_t runNumber,
32 AliRawReader* reader,
33 Bool_t histogram=kFALSE,
34 Bool_t useHPdecoder=kFALSE);
35
49419555 36 AliMUONTrackerRawDataMaker(AliRawReader* reader = 0x0,
37 Bool_t histogram=kFALSE,
38 Bool_t useHPdecoder=kFALSE);
515cc5b5 39
0145e89a 40 virtual ~AliMUONTrackerRawDataMaker();
41
e83120bd 42 Bool_t Add(const AliMUONTrackerRawDataMaker& other);
43
9016a84e 44 /// Whether we have a valid raw reader
0145e89a 45 Bool_t IsValid() const { return fRawReader != 0x0; }
46
9016a84e 47 /// Our data
0145e89a 48 AliMUONVTrackerData* Data() const { return fAccumulatedData; }
49
49419555 50 /// Whether we're only handling event-by-event data (i.e. no accumulation)
51 virtual Bool_t IsEventByEvent() const { return fIsEventByEvent; }
52
53 /// Set event-by-event mode
54 virtual void SetEventByEvent(Bool_t flag) { fIsEventByEvent = flag; }
55
56 /// We can be run if we have a reader
57 virtual Bool_t IsRunnable() const { return IsValid(); }
0145e89a 58
9016a84e 59 /// Whether we are running or not
0145e89a 60 virtual Bool_t IsRunning() const { return fIsRunning; }
61
9016a84e 62 /// Set the running status
0145e89a 63 virtual void SetRunning(Bool_t flag) { fIsRunning = flag; }
64
515cc5b5 65 Bool_t ProcessEvent();
66
0145e89a 67 Bool_t NextEvent();
68
69 void Print(Option_t* opt="") const;
70
71 void Rewind();
72
9016a84e 73 /// Get our source URI
0145e89a 74 virtual TString Source() const { return fSource.Data(); }
75
9016a84e 76 /// Set our source URI
0145e89a 77 void SetSource(const char* source) { fSource = source; }
78
d59411b9 79 /// Number of events seen
8741815f 80 Int_t NumberOfEvents() const { return fNumberOfEvents; }
d59411b9 81
49419555 82 Long64_t Merge(TCollection* li);
83
515cc5b5 84 void SetRawReader(AliRawReader* rawReader);
85
0145e89a 86private:
87 /// Not implemented
88 AliMUONTrackerRawDataMaker(const AliMUONTrackerRawDataMaker& rhs);
89 /// Not implemented
90 AliMUONTrackerRawDataMaker& operator=(const AliMUONTrackerRawDataMaker& rhs);
91
515cc5b5 92 void Ctor(Bool_t histogram);
93
0145e89a 94private:
515cc5b5 95 AliRawReader* fRawReader; //!< reader of the data (owner or not)
96 Bool_t fIsOwnerOfRawReader; //!< whether we must delete rawReader or not
49419555 97 AliMUONVTrackerData* fAccumulatedData; ///< data (owner)
0145e89a 98 AliMUONVStore* fOneEventData; ///< data for one event (owner)
0145e89a 99 TString fSource; ///< where the data comes from
100 Bool_t fIsRunning; ///< whether we are running or are paused
d59411b9 101 Int_t fNumberOfEvents; ///< number of events seen
49419555 102 Int_t fRunNumber; ///< run number of the data
103 Bool_t fIsEventByEvent; ///< we only keep one event's data (no accumulation)
515cc5b5 104 Bool_t fUseHPDecoder; ///< whether to use high performance decoder or not
0145e89a 105 static Int_t fgkCounter; ///< to count the number of instances
106
515cc5b5 107 ClassDef(AliMUONTrackerRawDataMaker,4) // Producer of AliMUONVTrackerData from raw data
0145e89a 108};
109
110#endif