CMS 3D CMS Logo

MuonDetIdAssociatorMaker.cc
Go to the documentation of this file.
1 // -*- C++ -*-
2 //
3 // Package: TrackingTools/TrackAssociator
4 // Class : MuonDetIdAssociatorMaker
5 //
6 // Implementation:
7 // [Notes on implementation]
8 //
9 // Original Author: Christopher Jones
10 // Created: Thu, 30 May 2019 15:05:57 GMT
11 //
12 
13 // system include files
14 
15 // user include files
21 #include "MuonDetIdAssociator.h"
22 
23 //
24 // constants, enums and typedefs
25 //
26 
27 //
28 // static data member definitions
29 //
30 
31 //
32 // constructors and destructor
33 //
36  : etaBinSize{pSet.getParameter<double>("etaBinSize")},
37  nPhi{pSet.getParameter<int>("nPhi")},
38  nEta{pSet.getParameter<int>("nEta")},
39  includeBadChambers_{pSet.getParameter<bool>("includeBadChambers")},
40  includeGEM_{pSet.getParameter<bool>("includeGEM")},
41  includeME0_{pSet.getParameter<bool>("includeME0")} {
42  iCollector.setConsumes(geomToken_).setConsumes(badChambersToken_);
43 }
44 
45 std::unique_ptr<DetIdAssociator> MuonDetIdAssociatorMaker::make(const DetIdAssociatorRecord& iRecord) const {
46  return std::unique_ptr<DetIdAssociator>(new MuonDetIdAssociator(nPhi,
47  nEta,
48  etaBinSize,
49  &iRecord.get(geomToken_),
50  &iRecord.get(badChambersToken_),
53  includeME0_));
54 }
T getParameter(std::string const &) const
edm::ESGetToken< GlobalTrackingGeometry, GlobalTrackingGeometryRecord > geomToken_
ProductT const & get(ESGetToken< ProductT, DepRecordT > const &iToken) const
MuonDetIdAssociatorMaker(edm::ParameterSet const &, edm::ESConsumesCollectorT< DetIdAssociatorRecord > &&)
std::unique_ptr< DetIdAssociator > make(const DetIdAssociatorRecord &) const final
edm::ESGetToken< CSCBadChambers, CSCBadChambersRcd > badChambersToken_