CMS 3D CMS Logo

DTTracoCard.h

Go to the documentation of this file.
00001 //-------------------------------------------------
00002 //
00015 //
00016 //--------------------------------------------------
00017 #ifndef DT_TRACO_CARD_H
00018 #define DT_TRACO_CARD_H
00019 
00020 //------------------------------------
00021 // Collaborating Class Declarations --
00022 //------------------------------------
00023 class DTTracoChip;
00024 class DTTracoTrig;
00025 class DTBtiCard;
00026 class DTTSTheta;
00027 class DTTrigGeom;
00028 
00029 //----------------------
00030 // Base Class Headers --
00031 //----------------------
00032 #include "L1Trigger/DTUtilities/interface/DTGeomSupplier.h"
00033 #include "DataFormats/MuonDetId/interface/DTTracoId.h"
00034 #include "L1TriggerConfig/DTTPGConfig/interface/DTConfig.h"
00035 #include "L1Trigger/DTTraco/interface/DTTracoTrigData.h"
00036 #include "L1Trigger/DTUtilities/interface/DTCache.h"
00037 #include "L1TriggerConfig/DTTPGConfig/interface/DTConfigTraco.h"
00038 #include "L1TriggerConfig/DTTPGConfig/interface/DTConfigManager.h"
00039 //#include "FWCore/ParameterSet/interface/ParameterSet.h"
00040 
00041 //---------------
00042 // C++ Headers --
00043 //---------------
00044 #include <vector>
00045 #include <map>
00046 
00047 //              ---------------------
00048 //              -- Class Interface --
00049 //              ---------------------
00050 
00051 typedef std::map< int,DTTracoChip*,std::less<int> >  TRACOContainer;
00052 typedef TRACOContainer::const_iterator TRACO_const_iter;
00053 typedef TRACOContainer::iterator TRACO_iter;
00054 
00055 typedef std::map<DTTracoId,DTConfigTraco> ConfTracoMap;
00056 
00057 typedef DTCache<DTTracoTrigData,std::vector<DTTracoTrigData> > TRACOCache;
00058   
00059 class DTTracoCard : public TRACOCache, public DTGeomSupplier {
00060 
00061   public:
00062 
00064     //DTTracoCard(DTTrigGeom*, DTBtiCard*, DTTSTheta*,edm::ParameterSet&);
00065     DTTracoCard(DTTrigGeom*, DTBtiCard*, DTTSTheta*);
00066 
00068     ~DTTracoCard();
00069 
00071     void clearCache();
00072 
00074     void setConfig(const DTConfigManager *conf);
00075 
00077     inline bool debug() {return _debug;}
00078 
00080     inline DTTSTheta* TSTh() const { return _tstheta; }
00081 
00083     DTTracoChip* getTRACO(int n) const;
00084 
00086     DTTracoChip* getTRACO(const DTTracoId& tracoid) const {
00087       return getTRACO(tracoid.traco());
00088     }
00089 
00091     std::vector<DTTracoChip*> tracoList();
00092 
00097     DTTracoTrig* storeTrigger(DTTracoTrigData);
00098 
00100     LocalPoint localPosition(const DTTrigData*) const;
00101 
00103     LocalVector localDirection(const DTTrigData*) const;
00104     
00106     virtual void reconstruct() { clearCache(); loadTRACO(); runTRACO(); }
00107 
00108   private:
00109 
00111     void loadTRACO();
00112 
00114     void runTRACO();
00115 
00117     DTTracoChip* activeGetTRACO(int);
00118 
00120     DTTracoChip* activeGetTRACO(const DTTracoId& tracoid) {
00121       return activeGetTRACO(tracoid.traco());
00122     }
00123 
00125     void localClear();
00126 
00128     DTConfigTraco* config_traco(const DTTracoId& tracoid) const; 
00129 
00130   private:
00131 
00132     DTBtiCard* _bticard;
00133     DTTSTheta* _tstheta;
00134 
00135     TRACOContainer _tracomap;
00136     ConfTracoMap _conf_traco_map;       //bti configuration map for this chamber
00137 
00138     bool _debug;
00139 };
00140 
00141 #endif

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