CMS 3D CMS Logo

RPCTriggerCrate.cc

Go to the documentation of this file.
00001 //---------------------------------------------------------------------------
00002 
00003 #include "L1Trigger/RPCTrigger/interface/RPCTriggerCrate.h"
00004 
00005 //---------------------------------------------------------------------------
00006 RPCTriggerCrate::RPCTriggerCrate(RPCTriggerConfiguration* triggerConfig, int tcNum):
00007   m_TCGhostBusterSorter(triggerConfig)
00008 {
00009   //m_TCGhostBusterSorter = tcGhostBusterSorter;
00010   m_TriggerConfig = triggerConfig;
00011   m_WasMuon = false;
00012 
00013   m_TCNumber = tcNum;
00014 
00015   for(int iTB = 0; iTB < triggerConfig->getTBsInTC(); iTB++)
00016     m_TBsVec.push_back(RPCTriggerBoard(triggerConfig, iTB, tcNum));
00017 }
00018 //----------------------------------------
00019 L1RpcTBMuonsVec RPCTriggerCrate::runTCGBSorter() {
00020   if(!m_WasMuon)
00021     return L1RpcTBMuonsVec();
00022 
00023   L1RpcTBMuonsVec2 tbMuonsVec2;
00024   for(unsigned int iTB = 0; iTB < m_TBsVec.size(); iTB++) {
00025     tbMuonsVec2.push_back(m_TBsVec[iTB].runTBGB());
00026   }
00027 
00028   m_WasMuon = false;
00029 
00030   if ( m_TriggerConfig->getDebugLevel()!=0){
00031 
00032     for (unsigned  int iTC = 0; iTC < tbMuonsVec2.size(); iTC++){
00033         for (unsigned  int iTB = 0; iTB < tbMuonsVec2[iTC].size(); iTB++){
00034 #ifndef _STAND_ALONE
00035             LogDebug("RPCHwDebug") << "GB 1 " << iTB << " "
00036               <<tbMuonsVec2[iTC][iTB].printDebugInfo(m_TriggerConfig->getDebugLevel());
00037 #else
00038           std::cout << "GB 1 " << "GB 1 " << iTB << " "
00039                   <<tbMuonsVec2[iTC][iTB].printDebugInfo(m_TriggerConfig->getDebugLevel())
00040                   << std::endl;
00041 #endif //_STAND_ALONE
00042         }
00043     }
00044 
00045   }
00046 
00047   return m_TCGhostBusterSorter.run(tbMuonsVec2);
00048 }
00049 
00050 
00052 void RPCTriggerCrate::runCone(const RPCLogCone& cone) {
00053   if(m_TBsVec[m_TriggerConfig->getTBNum(cone.getConeCrdnts())].runCone(cone))
00054     m_WasMuon = true;
00055 }

Generated on Tue Jun 9 17:40:25 2009 for CMSSW by  doxygen 1.5.4