]> git.uio.no Git - u/mrichter/AliRoot.git/blob - ANALYSIS/EventMixing/AliMixInputHandlerInfo.h
Port of new Event Mixing implementation
[u/mrichter/AliRoot.git] / ANALYSIS / EventMixing / AliMixInputHandlerInfo.h
1 //
2 // Class AliMixInputHandlerInfo
3 //
4 // AliMixInputHandlerInfo is interface with mixed
5 // input handlers
6 //
7 // author:
8 //        Martin Vala (martin.vala@cern.ch)
9 //
10 #ifndef ALIMIXINPUTHANDLERINFO_H
11 #define ALIMIXINPUTHANDLERINFO_H
12 #include <TArrayI.h>
13 #include <TNamed.h>
14
15 class TTree;
16 class TChain;
17 class TChainElement;
18 class AliInputEventHandler;
19 class AliMixInputHandlerInfo : public TNamed {
20
21 public:
22    AliMixInputHandlerInfo(const char *name = "defautlTree", const char *title = "Defautl tree");
23    virtual ~AliMixInputHandlerInfo();
24    TChain *GetChain();
25
26    void AddChain(TChain *chain);
27 //     void AddTreeToChain(TTree *tree);
28    void AddTreeToChain(const char *path);
29
30    void PrepareEntry(TChainElement *te, Long64_t entry, AliInputEventHandler *eh, Option_t *opt);
31
32    void SetZeroEntryNumber(Long64_t num) { fZeroEntryNumber = num; }
33    TChainElement *GetEntryInTree(Long64_t &entry);
34    Long64_t      GetEntries();
35
36 private:
37    TChain    *fChain;              // current chain
38    TArrayI   fChainEntriesArray;   // array of entries of every chaing
39    Long64_t  fZeroEntryNumber;     // zero entry number (will be used when we will delete not needed chains)
40    Bool_t    fNeedNotify;          // flag if Notify is needed for current input handler
41
42    AliMixInputHandlerInfo(const AliMixInputHandlerInfo &handler);
43    AliMixInputHandlerInfo &operator=(const AliMixInputHandlerInfo &handler);
44
45    ClassDef(AliMixInputHandlerInfo, 1); // Mix Input Handler info
46 };
47
48 #endif // ALIMIXINPUTHANDLERINFO_H