17#include "MdcGeomSvc/MdcGeomSvc.h"
34 for(
int i=0; i<
nGap; i++) {
42 m_idxTrkCandiVec.clear();
54 for(
int i=0; i<
nGap; i++) {
62 m_idxTrkCandiVec.clear();
71 vector<const MdcDigi*>
GetHit() {
return fHitsOfWire;}
73 if(fHitsOfWire.size()==0) {
return false;}
77 if(fHitsOfWire.size()==0||useflag==1) {
return true;}
82 if(i<
nGap)
return fPrevID[i];
86 if(i<
nGap)
return fNextID[i];
90 if(i<
nGap)
return fInnerID[i];
97 if(i<
nGap)
return fOuterID[i];
105 if(i<
nGap)
for(
int j=0; j<=i; j++) a.insert( a.end(), fOuterID[j].begin(), fOuterID[j].end() );
110 if(i<
nGap)
for(
int j=0; j<=i; j++) a.push_back( fNextID[j] );
115 vector<int> a = fAllNeiborID;
117 for(
int j=1; j<=i; j++) {
118 a.insert( a.end(), fOuterID[j].begin(), fOuterID[j].end() );
119 a.insert( a.end(), fInnerID[j].begin(), fInnerID[j].end() );
125 return fInnerID[0].size()+fOuterID[0].size()+(fPrevID[0]<0?0:1)+(fNextID[0]<0?0:1);
129 return (fInnerID[0].size()>0?1:0)+(fOuterID[0].size()>0?1:0)+(fPrevID[0]<0?0:1)+(fNextID[0]<0?0:1);
139 return fOuterID[0].size()==0&&fInnerID[0].size()>0;
151 if(nTypeNb==1)
return true;
158 if(nTypeNb==2)
if(fInnerID[0].size()>0&&fOuterID[0].size()>0) flag=
true;
165 if(nTypeNb==2)
if(fPrevID[0]>=0&&fNextID[0]>=0) flag=
true;
172 if(nTypeNb==1&&fInnerID[0].size()==0&&fOuterID[0].size()==0) flag=
true;
182 if(gap==0) fAllNeiborID.push_back(wireID);
189 if(gap==0) fAllNeiborID.push_back(wireID);
195 fInnerID[gap].push_back(wireID);
196 if(gap==0) fAllNeiborID.push_back(wireID);
202 fOuterID[gap].push_back(wireID);
203 if(gap==0) fAllNeiborID.push_back(wireID);
220 vector<int>::iterator
iter = std::remove(m_idxTrkCandiVec.begin(), m_idxTrkCandiVec.end(), idx);
221 m_idxTrkCandiVec.erase(
iter, m_idxTrkCandiVec.end());
230 int m_totalNearbyHits;
233 vector<int> fInnerID[
nGap];
234 vector<int> fOuterID[
nGap];
235 vector<int> fAllNeiborID;
236 vector<const MdcDigi*> fHitsOfWire;
238 vector<int> m_idxTrkCandiVec;
vector< int > GetInner(int i=0)
const MdcGeoWire * GetWire()
vector< const MdcDigi * > GetHit()
void RmTrkCandiIdx(int idx)
void AddOuter(int wireID, int gap=0)
vector< int > GetNeiborHits(int i)
void SetWire(const MdcGeoWire *aWire)
vector< int > GetOuter(int i=0)
void AddTrkCandiIdx(int idx)
void AddInner(int wireID, int gap=0)
void AddPrev(int wireID, int gap=0)
vector< int > GetOuterTot(int i=0)
int GetNTypesNeighborHits()
void SetUsedFlag(int flag=1)
void AddHit(const MdcDigi *aHit)
vector< int > GetNextAndOuterTot(int i=0)
void AddNext(int wireID, int gap=0)
vector< int > GetNeiborHits()