]>
Commit | Line | Data |
---|---|---|
5a5a1232 | 1 | // $Header$ |
2 | ||
3 | #ifndef ALIEVE_Event_H | |
4 | #define ALIEVE_Event_H | |
5 | ||
6f0b0040 | 6 | #include <Reve/EventBase.h> |
5a5a1232 | 7 | |
8 | class AliRunLoader; | |
9 | class AliESD; | |
3aecaefc | 10 | class AliESDfriend; |
5a5a1232 | 11 | |
12 | class TFile; | |
13 | class TTree; | |
14 | ||
15 | namespace Alieve { | |
16 | ||
6f0b0040 | 17 | class Event : public Reve::EventBase |
5a5a1232 | 18 | { |
19 | private: | |
265ecb21 | 20 | Event(const Event&); // Not implemented |
21 | Event& operator=(const Event&); // Not implemented | |
5a5a1232 | 22 | |
23 | protected: | |
24 | TString fPath; | |
25 | Int_t fEventId; | |
26 | ||
27 | AliRunLoader* fRunLoader; | |
28 | ||
29 | TFile* fESDFile; | |
30 | TTree* fESDTree; | |
31 | AliESD* fESD; | |
3aecaefc | 32 | TFile* fESDfriendFile; |
33 | TTree* fESDfriendTree; | |
34 | AliESDfriend* fESDfriend; | |
5a5a1232 | 35 | |
36 | static Bool_t fgUseRunLoader; | |
37 | static Bool_t fgUseESDTree; | |
753fdd1e | 38 | static Bool_t fgAvoidExcOnOpen; |
5a5a1232 | 39 | |
40 | public: | |
753fdd1e | 41 | static void Initialize(Bool_t use_runloader=kTRUE, Bool_t use_esd=kTRUE, |
42 | Bool_t avoid_exc_on_open=kTRUE); | |
5a5a1232 | 43 | |
44 | Event(); | |
45 | Event(TString path, Int_t ev=0); | |
46 | ||
47 | void Open(); | |
1eaa5849 | 48 | void GotoEvent(Int_t event); |
49 | void NextEvent() { GotoEvent(fEventId + 1); } | |
50 | void PrevEvent() { GotoEvent(fEventId - 1); } | |
5a5a1232 | 51 | void Close(); |
52 | ||
53 | Int_t GetEventId() const { return fEventId; } | |
54 | AliRunLoader* GetRunLoader() const { return fRunLoader; } | |
55 | TTree* GetESDTree() const { return fESDTree; } | |
56 | AliESD* GetESD() const { return fESD; } | |
3aecaefc | 57 | TTree* GetESDfriendTree() const { return fESDfriendTree; } |
58 | AliESDfriend* GetESDfriend() const { return fESDfriend; } | |
5a5a1232 | 59 | |
60 | virtual const Text_t* GetTitle() const { return fPath.Data(); } | |
61 | ||
62 | static AliRunLoader* AssertRunLoader(); | |
63 | static AliESD* AssertESD(); | |
3aecaefc | 64 | static AliESDfriend* AssertESDfriend(); |
5a5a1232 | 65 | |
66 | ClassDef(Event, 1); | |
67 | }; // endclass Event | |
68 | ||
69 | extern Event* gEvent; | |
70 | ||
71 | } | |
72 | ||
73 | #endif |