#include <CSCTriggerMapping.h>
Classes | |
struct | CSCTriggerConnection |
Public Types | |
typedef struct CSCTriggerMapping::CSCTriggerConnection | Connection |
Public Member Functions | |
void | addRecord (int rendcap, int rstation, int rsector, int rsubsector, int rcscid, int cendcap, int cstation, int csector, int csubsector, int ccscid) |
int | chamber (int endcap, int station, int sector, int subsector, int cscid) const |
CSCTriggerMapping () | |
Default constructor. More... | |
bool | debugV (void) const |
CSCDetId | detId (int endcap, int station, int sector, int subsector, int cscid, int layer=0) const |
virtual void | fill (void)=0 |
const std::string & | myName (void) const |
void | setDebugV (bool dbg) |
virtual | ~CSCTriggerMapping () |
Destructor. More... | |
Private Member Functions | |
virtual int | hwId (int endcap, int station, int sector, int subsector, int cscid) const =0 |
int | swId (int endcap, int station, int sector, int subsector, int cscid) const |
Private Attributes | |
bool | debugV_ |
std::map< int, int > | hw2sw_ |
std::vector< Connection > | mapping_ |
std::string | myName_ |
Defines the ids and labels in the mapping and supplies tramslation interface. A derived class must define how hardware labels map to a unique integer. A derived, concrete, class must define from where the mapping information comes.
Definition at line 21 of file CSCTriggerMapping.h.
Instead of a set of vectors of int use one vector of a set of ints Defines a connection between a chamber on a disc and a readout label. This is equivalent to the placement of a board in a crate, and a MPC to SR/SP optical connection. Construction of CSCDetIds is done using CSCTriggerNumbering.
variables with a 'r' prefix are readout-derived labels variables with a 'c' prefix are geometry-derived labels (c as in chamber label)
CSCTriggerMapping::CSCTriggerMapping | ( | ) |
|
virtual |
void CSCTriggerMapping::addRecord | ( | int | rendcap, |
int | rstation, | ||
int | rsector, | ||
int | rsubsector, | ||
int | rcscid, | ||
int | cendcap, | ||
int | cstation, | ||
int | csector, | ||
int | csubsector, | ||
int | ccscid | ||
) |
Add one record of info to mapping
Definition at line 33 of file CSCTriggerMapping.cc.
References gather_cfg::cout, debugV(), hw2sw_, hwId(), mapping_, myName_, evf::utils::sid, and swId().
Referenced by CSCTFUnpacker::CSCTFUnpacker(), CSCTriggerElectronicsMappingFromFile::fill(), and CSCTriggerMappingFromFile::fill().
int CSCTriggerMapping::chamber | ( | int | endcap, |
int | station, | ||
int | sector, | ||
int | subsector, | ||
int | cscid | ||
) | const |
Return chamber label corresponding to readout ids station, sector, subsector and cscid for given endcap endcap = 1 (+z), 2 (-z), station, sector, subsector, cscid (dmb slot/2)
Definition at line 9 of file CSCTriggerMapping.cc.
References gather_cfg::cout, debugV(), hw2sw_, hwId(), and myName_.
Referenced by detId(), CSCTriggerSimpleMapping::hwId(), geometryXMLparser.CSCAlignable::index(), and swId().
|
inline |
Status of debug printout flag
Definition at line 95 of file CSCTriggerMapping.h.
References debugV_.
Referenced by addRecord(), chamber(), CSCTriggerMappingFromFile::fill(), CSCTriggerElectronicsMappingFromFile::fill(), CSCTriggerElectronicsMapping::hwId(), and CSCTriggerSimpleMapping::hwId().
CSCDetId CSCTriggerMapping::detId | ( | int | endcap, |
int | station, | ||
int | sector, | ||
int | subsector, | ||
int | cscid, | ||
int | layer = 0 |
||
) | const |
Return CSCDetId for chamber/layer corresponding to readout ids station, sector, subsector and cscid for given endcap and layer no. 1-6, or for chamber if no layer no. supplied. Args: endcap = 1 (+z), 2 (-z), station, readout sector, readout subsector, readout cscid, layer#
Definition at line 27 of file CSCTriggerMapping.cc.
References chamber(), and CSCDetId.
Referenced by CSCTFUnpacker::produce().
|
pure virtual |
Fill mapping store
Implemented in CSCTriggerElectronicsMappingFromFile, and CSCTriggerMappingFromFile.
|
privatepure virtual |
Build a unique integer out of the readout electronics labels.
Implemented in CSCTriggerElectronicsMapping, and CSCTriggerSimpleMapping.
Referenced by addRecord(), and chamber().
|
inline |
Return class name
Definition at line 100 of file CSCTriggerMapping.h.
References myName_.
Referenced by CSCTriggerElectronicsMapping::hwId(), and CSCTriggerSimpleMapping::hwId().
|
inline |
|
private |
Build a unique integer out of chamber labels.
Translate to geometry labels then use rawId.
Definition at line 49 of file CSCTriggerMapping.cc.
References chamber(), CSCTriggerNumbering::chamberFromTriggerLabels(), CSCDetId::rawIdMaker(), relativeConstraints::ring, and CSCTriggerNumbering::ringFromTriggerLabels().
Referenced by addRecord().
|
private |
Definition at line 118 of file CSCTriggerMapping.h.
Referenced by debugV(), and setDebugV().
|
private |
Definition at line 120 of file CSCTriggerMapping.h.
Referenced by addRecord(), and chamber().
|
private |
Definition at line 119 of file CSCTriggerMapping.h.
Referenced by addRecord().
|
private |
Definition at line 117 of file CSCTriggerMapping.h.
Referenced by addRecord(), chamber(), and myName().