StRoot  1
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
StTrackTopologyMap.h
1 
5 /***************************************************************************
6  *
7  * $Id: StTrackTopologyMap.h,v 2.14 2018/03/27 02:41:00 genevb Exp $
8  *
9  * Author: Thomas Ullrich, AUg 1999
10  ***************************************************************************
11  *
12  * Description:
13  *
14  ***************************************************************************
15  *
16  * $Log: StTrackTopologyMap.h,v $
17  * Revision 2.14 2018/03/27 02:41:00 genevb
18  * iTPC modifications, plus proper use of booleans
19  *
20  * Revision 2.13 2016/02/24 22:01:12 ullrich
21  * Added method hasHitInSstLayer().
22  *
23  * Revision 2.12 2014/03/16 16:06:24 fisyak
24  * Xin\'s fix for HFT
25  *
26  * Revision 2.11 2007/11/07 00:54:54 ullrich
27  * Added PXL and IST.
28  *
29  * Revision 2.10 2005/06/23 19:04:24 ullrich
30  * Added overloaded version of hasHitInDetector() taking up to 6 args.
31  *
32  * Revision 2.9 2003/09/02 17:58:06 perev
33  * gcc 3.2 updates + WarnOff
34  *
35  * Revision 2.8 2002/02/22 22:56:53 jeromel
36  * Doxygen basic documentation in all header files. None of this is required
37  * for QM production.
38  *
39  * Revision 2.7 2001/04/24 21:32:07 genevb
40  * Additional helper functions
41  *
42  * Revision 2.6 2001/04/05 04:00:46 ullrich
43  * Replaced all (U)Long_t by (U)Int_t and all redundant ROOT typedefs.
44  *
45  * Revision 2.5 2000/05/17 17:21:38 ullrich
46  * New method largestGap() and new output operator.
47  *
48  * Revision 2.4 2000/04/12 19:44:03 genevb
49  * Reimplement mMap data members as individual unsigned ints
50  *
51  * Revision 2.3 2000/04/10 19:59:33 genevb
52  * StRoot/StEvent/doc/tex/
53  *
54  * Revision 2.2 1999/12/13 20:16:39 ullrich
55  * Changed numbering scheme for hw_position unpack methods (STAR conventions).
56  *
57  * Revision 2.1 1999/10/13 19:44:17 ullrich
58  * Initial Revision
59  *
60  **************************************************************************/
61 #ifndef StTrackTopologyMap_hh
62 #define StTrackTopologyMap_hh
63 
64 #include <Stiostream.h>
65 #include "StObject.h"
66 #include "StEnumerations.h"
67 
68 class StTrackTopologyMap : public StObject {
69 public:
71  StTrackTopologyMap(unsigned int, unsigned int, unsigned long long = 0);
72  StTrackTopologyMap(const unsigned long*, unsigned long long = 0);
73  StTrackTopologyMap(const unsigned int*, unsigned long long = 0);
74  // StTrackTopologyMap(const StTrackTopologyMap&); use default
75  // StTrackTopologyMap& operator=(const StTrackTopologyMap&); use default
77 
78  bool primaryVertexUsed() const;
79  unsigned int numberOfHits(StDetectorId) const;
80  bool hasHitInDetector(StDetectorId) const;
81  bool hasHitInDetector(StDetectorId, StDetectorId,
82  StDetectorId = kUnknownId, StDetectorId = kUnknownId,
83  StDetectorId = kUnknownId, StDetectorId = kUnknownId) const;
84  bool hasHitInRow(StDetectorId, unsigned int) const; // first row = 1
85  bool hasHitInSvtLayer(unsigned int) const; // first layer = 1
86  bool hasHitInPxlLayer(unsigned int) const; // first layer = 1
87  bool hasHitInIstLayer(unsigned int) const; // first layer = 1
88  bool hasHitInSsdLayer(unsigned int) const; // first layer = 1
89  bool hasHitInSstLayer(unsigned int) const;
90 
91  bool trackTpcOnly() const;
92  bool trackSvtOnly() const;
93  bool trackTpcSvt() const;
94  bool trackFtpcEast() const;
95  bool trackFtpcWest() const;
96  bool trackFtpc() const;
97 
98  bool turnAroundFlag() const;
99  unsigned long long data(unsigned int) const;
100 
101  int largestGap(StDetectorId) const;
102 
103 protected:
104  bool bit(int) const; // range 0-63
105  bool iTpcBit(int) const; // range 0-63
106  bool ftpcFormat() const;
107  bool hftFormat() const; // TPC tracks with HFT (Run13++) hit format
108 
109 private:
110  UInt_t mMap0;
111  UInt_t mMap1;
112  ULong64_t mMap_iTpc;
113 
114  ClassDef(StTrackTopologyMap,2)
115 };
116 
117 ostream& operator<< (ostream&, const StTrackTopologyMap&);
118 
119 inline bool StTrackTopologyMap::hasHitInSstLayer(unsigned int val) const
120 {
121  return hasHitInSsdLayer(val);
122 }
123 
124 #endif