LCIO  "2.7.4"
 All Classes Namespaces Functions Variables Typedefs Friends Pages
ILDConf.h
1 // -*- C++ -*-
2 #ifndef UTIL_ILDConf_H
3 #define UTIL_ILDConf_H 1
4 
5 #include <string>
6 #include "CellIDEncoder.h"
7 #include "CellIDDecoder.h"
8 
9 #include "BitSet32.h"
10 
11 // Some useful definitions that are used in the ILD software framework - in particular for
12 // encoding and decoding cellIDs.
13 
14 namespace UTIL {
15 
16 
17 
18 
25  struct ILDCellID0 {
26 
39  static std::string encoder_string ;
40 
43  static const unsigned subdet ;
44 
47  static const unsigned side ;
48 
51  static const unsigned layer ;
52 
54  static const unsigned module ;
55 
57  static const unsigned sensor ;
58 
59  };
60 
61 
62 
66  template <class T>
67  class ILDCellIDEncoder : public CellIDEncoder<T> {
68 
69  public:
70 
74  CellIDEncoder<T>( ILDCellID0::encoder_string, col ) {}
75 
76 
80  ILDCellIDEncoder( const std::string& cellIDEncoding , EVENT::LCCollection* col) :
81  CellIDEncoder<T>( std::string( ILDCellID0::encoder_string + "," + cellIDEncoding ) , col ) {
82 
83  if( cellIDEncoding.size() == 0 ){
84  throw EVENT::Exception(" ILDCellIDEncoder::ILDCellIDEncoder: cannot initilize with empty string ! " ) ;
85  }
86  }
87  } ;
88 
89 
90 
91 
92 
99  struct ILDDetID{
100 
101 
102  static const int NOTUSED ;
103  static const int VXD ;
104  static const int SIT ;
105  static const int FTD ;
106  static const int TPC ;
107  static const int SET ;
108  static const int ETD ;
109 
110  static const int ECAL ;
111  static const int ECAL_PLUG ;
112  static const int HCAL ;
113  static const int HCAL_RING ;
114  static const int LCAL ;
115  static const int BCAL ;
116  static const int LHCAL ;
117  static const int YOKE ;
118  static const int COIL ;
119  static const int ECAL_ENDCAP ;
120  static const int HCAL_ENDCAP ;
121  static const int YOKE_ENDCAP ;
122 
123  static const int bwd ;
124  static const int barrel ;
125  static const int fwd ;
126  } ;
127 
135  static const int COMPOSITE_SPACEPOINT ; // i.e. a 3D space-point composed of two independent strip measurements
136  static const int ONE_DIMENSIONAL; // e.g. a strip measurment
137 
138  } ;
139 
146  static const int USED_IN_FIT ;
147  static const int USED_IN_TRACK ;
148  static const int DOUBLE_HIT_CANDIDATE ;
149  static const int GOOD ;
150  } ;
151 
152 
153 
154 } // namespace UTIL
155 #endif // ifndef UTIL_ILDConf_H
Base exception class for LCIO - all other exceptions extend this.
Definition: Exceptions.h:21
ILDCellIDEncoder(EVENT::LCCollection *col)
Constructor for using the canonical cellID0 as defined in ILDCellID0::encoder_string - cellID1 will n...
Definition: ILDConf.h:73
Define integer constants for bits of the the lcio tracker hit type used in the context of ILD reconst...
Definition: ILDConf.h:134
static std::string encoder_string
The canonical encoding string to be used for writing the CellID0 with the CellIDEncoder<T>: ...
Definition: ILDConf.h:39
static const unsigned layer
Index of the field layer in encoder_string - local sub detector layer ID starting from 0 going away f...
Definition: ILDConf.h:51
static const unsigned side
Index of the field side in encoder_string - one of DetID::bwd, DetID::barrel, DetID::fwd.
Definition: ILDConf.h:47
static const unsigned subdet
Index of the field subdet in encoder_string - sub detector Id as defined in DetID, e.g.
Definition: ILDConf.h:43
Define integer constants for identifying ILD sub detectors.
Definition: ILDConf.h:99
static const unsigned sensor
Index of the field sensor in encoder_string - sensor ID as defined for the given subdetetor module...
Definition: ILDConf.h:57
Define integer constants for bits of the the lcio tracker hit quality used in the context of ILD reco...
Definition: ILDConf.h:145
Specialization for SimTrackerHits that have only one cellID.
Definition: CellIDEncoder.h:100
The generic collection used in LCIO.
Definition: LCCollection.h:29
static const unsigned module
Index of the field module in encoder_string - module ID as defined for the given subdetetor.
Definition: ILDConf.h:54
Special wrapper to the CellIDEncoder<T> that enforces cellID0 to use the encoder string defined in IL...
Definition: ILDConf.h:67
ILDCellIDEncoder(const std::string &cellIDEncoding, EVENT::LCCollection *col)
Constructor that prepends given ILDCellID0::encoder_string to the given encoding string.
Definition: ILDConf.h:80
Helper class to define constants for the canonical encoding of the CellID0 in tracking sub detectors ...
Definition: ILDConf.h:25