Starting from root v5-19-04 we need also pthread library.
[u/mrichter/AliRoot.git] / STEER / AliVEvent.h
CommitLineData
6bc03c45 1// -*- mode: C++ -*-
2#ifndef ALIVEVENT_H
3#define ALIVEVENT_H
4/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
5 * See cxx source for full Copyright notice */
6
7
8/* $Id$ */
9
10//-------------------------------------------------------------------------
11// Class AliVEvent
12//
13// Origin: Markus Oldenburg, CERN, Markus.Oldenburg@cern.ch
14//-------------------------------------------------------------------------
15
16#include <TObject.h>
17#include <TTree.h>
18#include "AliVHeader.h"
19#include "AliVParticle.h"
20
21class AliVEvent : public TObject {
22
23public:
24
25 AliVEvent() { }
26 virtual ~AliVEvent() { }
27 AliVEvent(const AliVEvent& vEvnt);
28 AliVEvent& operator=(const AliVEvent& vEvnt);
29
30 // Services
31 virtual void AddObject(TObject* obj) = 0;
32 virtual TObject* FindListObject(const char *name) = 0;
33 virtual TList* GetList() const = 0;
34
35 virtual void CreateStdContent() = 0;
36 virtual void GetStdContent() = 0;
37
1d0dd492 38 virtual void ReadFromTree(TTree *tree, Option_t* opt) = 0;
6bc03c45 39 virtual const void WriteToTree(TTree* tree) const = 0;
40
41 //virtual void Reset() = 0;
42 //virtual void ResetStdContent() = 0;
43 virtual void SetStdNames() = 0;
44
45 virtual void Print(Option_t *option="") const = 0;
46
47 // Header
48 virtual AliVHeader* GetHeader() const = 0;
49
50 // Delegated methods for fESDRun or AODHeader
51
52 virtual void SetRunNumber(Int_t n) = 0;
53 virtual void SetPeriodNumber(UInt_t n) = 0;
54 virtual void SetMagneticField(Double_t mf) = 0;
55
56 virtual Int_t GetRunNumber() const = 0;
57 virtual UInt_t GetPeriodNumber() const = 0;
58 virtual Double_t GetMagneticField() const = 0;
59
60 // Delegated methods for fHeader
61 virtual void SetOrbitNumber(UInt_t n) = 0;
62 virtual void SetBunchCrossNumber(UShort_t n) = 0;
63 virtual void SetEventType(UInt_t eventType)= 0;
64 virtual void SetTriggerMask(ULong64_t n) = 0;
65 virtual void SetTriggerCluster(UChar_t n) = 0;
66
67 virtual UInt_t GetOrbitNumber() const = 0;
68 virtual UShort_t GetBunchCrossNumber() const = 0;
69 virtual UInt_t GetEventType() const = 0;
70 virtual ULong64_t GetTriggerMask() const = 0;
71 virtual UChar_t GetTriggerCluster() const = 0;
72
73 virtual Double_t GetZDCN1Energy() const = 0;
74 virtual Double_t GetZDCP1Energy() const = 0;
75 virtual Double_t GetZDCN2Energy() const = 0;
76 virtual Double_t GetZDCP2Energy() const = 0;
a85132e7 77 virtual Double_t GetZDCEMEnergy(Int_t i) const = 0;
6bc03c45 78
79 // Tracks
80 virtual AliVParticle *GetTrack(Int_t i) const = 0;
81 //virtual Int_t AddTrack(const AliVParticle *t) = 0;
82 virtual Int_t GetNumberOfTracks() const = 0;
83
84 //---------- end of new stuff
85
86
87 /* to be considered to go in here be implemented
88
89 void SetPrimaryVertex(const AliESDVertex *vertex) {
90 *fPrimaryVertex = *vertex;
91 fPrimaryVertex->SetName("PrimaryVertex");// error prone use class wide names?
92 }
93 const AliESDVertex *GetPrimaryVertex() const {return fPrimaryVertex;}
94
95 void SetMultiplicity(const AliMultiplicity *mul) {
96 *fSPDMult = *mul;
97 // CKB
98 // new (&fSPDMult) AliMultiplicity(*mul);
99 }
100 const AliMultiplicity *GetMultiplicity() const {return fSPDMult;}
101
102
103 AliESDMuonTrack *GetMuonTrack(Int_t i) const {
104 return (AliESDMuonTrack *)fMuonTracks->UncheckedAt(i);
105 }
106 void AddMuonTrack(const AliESDMuonTrack *t) {
107 TClonesArray &fmu = *fMuonTracks;
108 new(fmu[fMuonTracks->GetEntriesFast()]) AliESDMuonTrack(*t);
109 }
110
111 AliESDv0 *GetV0(Int_t i) const {
112 return (AliESDv0*)fV0s->UncheckedAt(i);
113 }
114 Int_t AddV0(const AliESDv0 *v);
115
116 AliESDcascade *GetCascade(Int_t i) const {
117 return (AliESDcascade *)fCascades->UncheckedAt(i);
118 }
119 void AddCascade(const AliESDcascade *c) {
120 TClonesArray &fc = *fCascades;
121 new(fc[fCascades->GetEntriesFast()]) AliESDcascade(*c);
122 }
123
124 AliESDkink *GetKink(Int_t i) const {
125 return (AliESDkink *)fKinks->UncheckedAt(i);
126 }
127 Int_t AddKink(const AliESDkink *c);
128
129 AliESDCaloCluster *GetCaloCluster(Int_t i) const {
130 return (AliESDCaloCluster *)fCaloClusters->UncheckedAt(i);
131 }
132 Int_t AddCaloCluster(const AliESDCaloCluster *c);
133
134 Int_t GetNumberOfMuonTracks() const {return fMuonTracks->GetEntriesFast();}
135 Int_t GetNumberOfV0s() const {return fV0s->GetEntriesFast();}
136 Int_t GetNumberOfCascades() const {return fCascades->GetEntriesFast();}
137 Int_t GetNumberOfKinks() const {return fKinks->GetEntriesFast();}
138 Int_t GetNumberOfCaloClusters() const {return fCaloClusters->GetEntriesFast();}
139
140 */
141
142 ClassDef(AliVEvent,0) // base class for AliEvent data
143};
144#endif
145