CMS 3D CMS Logo

CSCAnodeData.cc
Go to the documentation of this file.
7 #include <cstring> // for bzero
8 
10  : firmwareVersion(header.alctFirmwareVersion()) {
11  if (firmwareVersion == 2006) {
12  theData = std::shared_ptr<CSCAnodeDataFormat>(new CSCAnodeData2006(header));
13  } else {
14  theData = std::shared_ptr<CSCAnodeDataFormat>(new CSCAnodeData2007(header));
15  }
16 }
17 
18 // initialize
19 CSCAnodeData::CSCAnodeData(const CSCALCTHeader &header, const unsigned short *buf)
20  : firmwareVersion(header.alctFirmwareVersion()) {
21  if (firmwareVersion == 2006) {
22  theData = std::shared_ptr<CSCAnodeDataFormat>(new CSCAnodeData2006(header, buf));
23  } else {
24  theData = std::shared_ptr<CSCAnodeDataFormat>(new CSCAnodeData2007(header, buf));
25  }
26 }
27 
28 std::vector<std::vector<CSCWireDigi> > CSCAnodeData::wireDigis() const {
29  std::vector<std::vector<CSCWireDigi> > result;
31  result.push_back(wireDigis(layer));
32  }
33  return result;
34 }
std::vector< std::vector< CSCWireDigi > > wireDigis() const
Definition: CSCAnodeData.cc:28
CSCAnodeData(const CSCALCTHeader &)
a blank one, for Monte Carlo
Definition: CSCAnodeData.cc:9
int firmwareVersion
Definition: CSCAnodeData.h:30
constexpr std::array< uint8_t, layerIndexSize< TrackerTraits > > layer
static int minLayerId()
Definition: CSCDetId.h:242
std::shared_ptr< CSCAnodeDataFormat > theData
Definition: CSCAnodeData.h:29
static int maxLayerId()
Definition: CSCDetId.h:243