]> git.uio.no Git - u/mrichter/AliRoot.git/blob - PWG4/JCORRAN/AliPhJPhotonList.h
memory leak fixed
[u/mrichter/AliRoot.git] / PWG4 / JCORRAN / AliPhJPhotonList.h
1 // $Id: AliPhJPhotonList.h,v 1.4 2008/05/08 13:44:45 djkim Exp $
2
3 ////////////////////////////////////////////////////
4 /*!
5   \file AliPhJPhotonList.h
6   \brief
7   \author J. Rak, D.J.Kim, R.Diaz (University of Jyvaskyla)
8   \email: djkim@jyu.fi
9   \version $Revision: 1.4 $
10   \date $Date: 2008/05/08 13:44:45 $
11 */
12 ////////////////////////////////////////////////////
13
14 #ifndef ALIPHJPHOTONLIST_H
15 #define ALIPHJPHOTONLIST_H
16
17
18 #include "TClonesArray.h"
19 #include <iostream>
20 #include <stdlib.h>
21
22 #include "JConst.h"
23 #include "AliPhJPhoton.h"
24 #include "AliJPhoton.h"
25
26 //class TClonesArray;
27 //class AliJPhoton;
28 //class AliPhJPhoton;
29
30 class AliPhJPhotonList : public TObject {
31
32 public:
33   AliPhJPhotonList();
34   AliPhJPhotonList(expName exp);
35   AliPhJPhotonList(const AliPhJPhotonList& a);
36   virtual ~AliPhJPhotonList();
37
38   void Reset();
39
40   //getters
41   unsigned short GetNPhotons() const { return fPhotons; }
42   AliPhJPhoton*  GetPhoton(const unsigned int iph); 
43   AliJPhoton*    GetAliJPhoton(const unsigned int iph);    // ALICE getter
44   //setters
45   void SetNPhotons(const unsigned short nph) { fPhotons = nph; }
46   int  SetTClonesArraySize(const unsigned int nph);
47   // add Photon
48   void AddAliJPhoton(const unsigned int iph);     // ALICE add
49
50   AliPhJPhotonList& operator=(const AliPhJPhotonList& list);
51
52 protected:
53   TClonesArray *GetList() const { return fPhotonList; }
54   TClonesArray *fPhotonList; //photon  list
55   unsigned short fPhotons;   //number of photons in the list
56
57 private:
58   ClassDef(AliPhJPhotonList,1);
59
60 };
61
62 #endif