49 std::vector<RPCLogHit> logHits;
50 std::vector<RPCLogHit> logHitsFromUncomp;
55 short int digiIndex = 0;
57 for (detUnitIt=rpcDigis->begin();
58 detUnitIt!=rpcDigis->end();
61 const RPCDetId&
id = (*detUnitIt).first;
63 uint32_t rawId =
id.
rawId();
67 std::pair<L1RPCConeBuilder::TCompressedConVec::const_iterator, L1RPCConeBuilder::TCompressedConVec::const_iterator>
68 compressedConnPair = coneBuilder->getCompConVec(rawId);
77 if ( digiIt->bx() < bxOrDef->getFirstBX() +
bx || digiIt->bx() > bxOrDef->getLastBX() +
bx ){
84 std::pair<L1RPCConeBuilder::TStripConVec::const_iterator, L1RPCConeBuilder::TStripConVec::const_iterator>
85 itPair = coneBuilder->getConVec(rawId,digiIt->strip());
87 L1RPCConeBuilder::TStripConVec::const_iterator it = itPair.first;
89 for (; it!=itPair.second;++it){
91 if ( hwConfig->isActive(it->m_tower, it->m_PAC) ){
93 RPCLogHit lh(it->m_tower, it->m_PAC, it->m_logplane, it->m_logstrip);
94 lh.setDigiIdx(digiIndex);
95 logHitsFromUncomp.push_back(
lh );
107 L1RPCConeBuilder::TCompressedConVec::const_iterator itComp = compressedConnPair.first;
108 for (; itComp!=compressedConnPair.second; ++itComp){
109 if ( hwConfig->isActive(itComp->m_tower, itComp->m_PAC)){
110 int logstrip = itComp->getLogStrip(digiIt->strip(),coneDef->getLPSizeVec());
112 RPCLogHit lh(itComp->m_tower, itComp->m_PAC, itComp->m_logplane, logstrip );
113 lh.setDigiIdx(digiIndex);
114 logHits.push_back(
lh );
133 std::vector<RPCLogHit>::iterator itLHitUncomp = logHitsFromUncomp.begin();
134 std::vector<RPCLogHit>::iterator itLHitComp;
137 for(;itLHitUncomp != logHitsFromUncomp.end(); ++itLHitUncomp) {
138 for (itLHitComp = logHits.begin(); itLHitComp != logHits.end(); ++itLHitComp){
140 if ( itLHitComp->getTower() == itLHitUncomp->getTower()
141 && itLHitComp->getLogSector() == itLHitUncomp->getLogSector()
142 && itLHitComp->getLogSegment() == itLHitUncomp->getLogSegment()
143 && itLHitComp->getlogPlaneNumber() == itLHitUncomp->getlogPlaneNumber() )
147 *itLHitUncomp = *itLHitComp;
154 for(;itLHitUncomp != logHitsFromUncomp.end(); ++itLHitUncomp) {
155 bool present =
false;
156 for (
unsigned int i=0;
i < logHits.size(); ++
i)
159 if ( logHits[
i].getTower() == itLHitUncomp->getTower()
160 && logHits[
i].getLogSector() == itLHitUncomp->getLogSector()
161 && logHits[
i].getLogSegment() == itLHitUncomp->getLogSegment()
162 && logHits[
i].getlogPlaneNumber() == itLHitUncomp->getlogPlaneNumber() )
172 logHits.push_back(*itLHitUncomp);
179 std::vector<RPCLogHit>::iterator p_lhit;
180 for (p_lhit = logHits.begin(); p_lhit != logHits.end(); ++p_lhit){
182 bool hitTaken =
false;
183 L1RpcLogConesVec::iterator p_cone;
184 for (p_cone = ActiveCones.begin(); p_cone != ActiveCones.end(); p_cone++){
185 hitTaken = p_cone->addLogHit(*p_lhit);
192 newcone.setIdx(ActiveCones.size());
193 ActiveCones.push_back(newcone);
uint32_t rawId() const
get the raw id
std::vector< RPCDigi >::const_iterator const_iterator
std::pair< const_iterator, const_iterator > Range
std::vector< RPCLogCone > L1RpcLogConesVec