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

Annotation of /gp2root/pCatHit.h

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.1.1.1 - (hide annotations) (download) (vendor branch)
Wed Apr 19 23:35:57 2006 UTC (18 years, 7 months ago) by pamela
Branch: v1r0
CVS Tags: start
Changes since 1.1: +0 -0 lines
File MIME type: text/plain
First release

1 pamela 1.1 #ifndef PCATHIT_H
2     #define PCATHIT_H
3     #include <iostream>
4     #include "pHit.h"
5     #include "pCatID.h"
6    
7     using std::cout;
8     using std::endl;
9    
10     class pCatHit: public pHit {
11    
12     public:
13    
14     pCatHit(){};
15     pCatHit(const char *c){
16     int *temp = (int*) c;
17     SetIpart( *temp++ );
18     SetHitID( new pCatID((char*)temp ));
19     temp++;
20     SetXin( *((float*)temp) );
21     temp++;
22     SetYin( *((float*)temp) );
23     temp++;
24     SetZin( *((float*)temp) );
25     temp++;
26     SetXout( *((float*)temp) );
27     temp++;
28     SetYout( *((float*)temp) );
29     temp++;
30     SetZout( *((float*)temp) );
31     temp++;
32     SetErel( *((float*)temp) );
33     temp++;
34     SetTime( *((float*)temp) );
35     temp++;
36     SetPath( *((float*)temp) );
37     temp++;
38     SetP0( *((float*)temp) );
39     }
40    
41     void SetXout(const float & x){_xout=x;}
42     void SetYout(const float & x){_yout=x;}
43     void SetZout(const float & x){_zout=x;}
44     void SetTime(const float & x){_time=x;}
45     void SetPath(const float & x){_path=x;}
46    
47     float GetXout() const {return _xout;}
48     float GetYout() const {return _yout;}
49     float GetZout() const {return _zout;}
50     float GetTime() const {return _time;}
51     float GetPath() const {return _path;}
52    
53     void Print() const {
54     cout << "pCatHit : " << endl;
55     GetHitID()->Print() ;
56     cout << " Ipart = " << GetIpart() << endl;
57     cout << " xin,yin,zin = "
58     << GetXin() <<", "
59     << GetYin() <<", "
60     << GetZin() << endl;
61     cout << " xout,yout,zout = "
62     << GetXout() <<", "
63     << GetYout() <<", "
64     << GetZout() << endl;
65    
66     cout << " erel, time, path, p0= "
67     << GetErel() << ", "
68     << GetTime() << ", "
69     << GetPath() << ", "
70     << GetP0() << endl;
71     };
72    
73     private:
74     float _xout,_yout,_zout;
75     float _time,_path;
76     };
77    
78     #endif //PCATHIT_H

  ViewVC Help
Powered by ViewVC 1.1.23