/[PAMELA software]/gp2root/pHit.h
ViewVC logotype

Annotation of /gp2root/pHit.h

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.2 - (hide annotations) (download)
Sun Oct 22 08:26:57 2006 UTC (18 years, 1 month ago) by cafagna
Branch: MAIN
CVS Tags: v0r9, v0r10, HEAD
Changes since 1.1: +20 -6 lines
File MIME type: text/plain
Stable version, lot of changes, ROOT support included, persistency not yet activated

1 pamela 1.1 #ifndef PHIT_H
2     #define PHIT_H
3    
4     #include <vector>
5     #include "pHitID.h"
6 cafagna 1.2 #include "TObject.h"
7 pamela 1.1
8 cafagna 1.2 class pHit :public TObject {
9 pamela 1.1
10     public:
11    
12 cafagna 1.2 pHit() {
13     _xin=_yin=_zin=_erel=_p0=0.;
14     _ipart=0;
15     SetHitID(0);
16    
17     };
18    
19     pHit( const float & xin, const float &yin,const float &zin,
20     const float & erel,const float & p0, const int &ipart,
21     pHitID *hid):
22 pamela 1.1 _xin(xin), _yin(yin), _zin(zin), _erel(erel), _p0(p0), _ipart(ipart)
23     {
24     SetHitID(hid);
25     }
26    
27 cafagna 1.2 virtual ~pHit(){};
28 pamela 1.1 void SetHitID(pHitID * hid){_hid=hid;}
29     void SetXin(const float & x){_xin=x;}
30     void SetYin(const float & x){_yin=x;}
31     void SetZin(const float & x){_zin=x;}
32     void SetErel(const float & x){_erel=x;}
33     void SetP0(const float & x){_p0=x;}
34     void SetIpart(const int & i){_ipart=i;}
35    
36     pHitID* GetHitID() const { return _hid;}
37     float GetXin() const {return _xin;}
38     float GetYin() const {return _yin;}
39     float GetZin() const {return _zin;}
40     float GetErel() const {return _erel;}
41     float GetP0() const {return _p0;}
42     int GetIpart()const {return _ipart;}
43    
44     virtual void Print() const =0;
45    
46 cafagna 1.2
47 pamela 1.1 private:
48     float _xin,_yin,_zin;
49     float _erel;
50     float _p0;
51     int _ipart;
52     pHitID *_hid;
53 cafagna 1.2
54     public:
55     //#ifndef __GNUC__
56     ClassDef(pHit,1);
57     //#endif
58 pamela 1.1 };
59    
60     typedef std::vector<pHit*> pHitColl;
61    
62     #endif //PHIT_H
63 cafagna 1.2

  ViewVC Help
Powered by ViewVC 1.1.23