00001
00002 #include "KalFitAlg/KalFitList.h"
00003 #include "KalFitAlg/KalFitLayer_Mdc.h"
00004 #include "KalFitAlg/KalFitSuper_Mdc.h"
00005 #include "KalFitAlg/KalFitWire.h"
00006
00007
00008 const unsigned int
00009 KalFitSuper_Mdc::_neighborsMask[6] = {452,420,340,172,92,60};
00010
00011
00012
00013
00014
00015
00016
00017 KalFitSuper_Mdc::KalFitSuper_Mdc(const int firstWireID,const int NWire,
00018 const int firstLayerID,const int NLayer,
00019 const int superLayerID)
00020 : _superLayerId(superLayerID),
00021 _firstWireId(firstWireID),
00022 _Nwire(NWire),
00023 _firstLayerId(firstLayerID),
00024 _Nlayer(NLayer),
00025 _wireHits(*(new KalFitList<KalFitWire *>(500))),
00026 _singleHits(*(new KalFitList<KalFitWire *>(100)))
00027 {
00028
00029 }
00030
00031 KalFitSuper_Mdc::~KalFitSuper_Mdc()
00032 {
00033 clear();
00034 delete &_wireHits;
00035 delete &_singleHits;
00036 }
00037
00038 void
00039 KalFitSuper_Mdc::clear(void)
00040 {
00041 if(_wireHits.length()){
00042 register KalFitWire ** hptr = _wireHits.firstPtr();
00043 KalFitWire ** const last = _wireHits.lastPtr();
00044 do {(**hptr).state(WireHitInvalid);}while((long)(hptr++)^(long)last);
00045 _wireHits.clear();
00046 }
00047 }
00048
00049 const int
00050 KalFitSuper_Mdc::nWire(void) const{
00051 return _Nwire;
00052 }
00053
00054
00055 const int
00056 KalFitSuper_Mdc::nLayer(void) const{
00057 return _Nlayer;
00058 }
00059
00060
00061 const int
00062 KalFitSuper_Mdc::localMaxId(void) const{
00063 return (_Nwire - 1);
00064 }
00065
00066
00067 const int
00068 KalFitSuper_Mdc::layerMaxId(void) const{
00069 return (_Nlayer - 1);
00070 }
00071
00072
00073 const int
00074 KalFitSuper_Mdc::superLayerId(void) const{
00075 return _superLayerId;
00076 }
00077