StRoot  1
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
StG2TTpcChair.h
1 #ifndef STAR_StG2TTpcChair
2 #define STAR_StG2TTpcChair
3 // This chair privides the custom methods to the packed
5 // tcl_hit columns:
6 // long track; /* track_id*1000+position on on a track (starts from 1) */
7 // short row; /* 100*isector TPC row number */
8 // and provide extra row check:
10 
11 #include "StHitChair.h"
12 #include "tables/St_g2t_tpc_hit_Table.h"
13 #include "StDetectorDefinitions.h"
14 
15 class StG2TTpcChair : public StHitChair {
16  protected:
17  StG2TTpcChair() {;}
18  public:
19  StG2TTpcChair(St_g2t_tpc_hit *hits): StHitChair(hits){;}
20  virtual ~StG2TTpcChair(){;}
21 
22  virtual Int_t Sector(Int_t i) const {return (fTab_g2t[i].volume_id/100)%100;}
23  virtual Int_t PadRow(Int_t i) const {return fTab_g2t[i].volume_id%100;}
24  virtual Int_t TrackId(Int_t i) const {return fTab_g2t[i].track_p;}
25 // virtual Int_t HitPosition(Int_t i) const;
26  virtual Int_t DetectorId(Int_t i) const{return kTpcIdentifier;}
27  virtual Float_t GetX(Int_t i) const{return fTab_g2t[i].x[0];}
28  virtual Float_t GetY(Int_t i) const{return fTab_g2t[i].x[1];}
29  virtual Float_t GetZ(Int_t i) const{return fTab_g2t[i].x[2];}
30  virtual Float_t GetXError(Int_t i) const{return 0.;}
31  virtual Float_t GetYError(Int_t i) const{return 0.;}
32  virtual Float_t GetZError(Int_t i) const{return 0.;}
33 //===============================================
34 
35  ClassDef(StG2TTpcChair,0)
36 };
37 
38 
39 #endif
40