CMS 3D CMS Logo

FastTimeTopologyBuilder.cc
Go to the documentation of this file.
1 // -*- C++ -*-
2 //
3 // Package: CaloEventSetup
4 // Class: FastTimeTopologyBuilder
5 //
13 //
14 // Original Author: Sunanda Banerjee
15 //
16 //
17 
18 
19 // system include files
20 #include <memory>
21 
22 // user include files
25 
34 
35 //#define EDM_ML_DEBUG
36 
37 //
38 // class decleration
39 //
40 
42 
43 public:
45  ~FastTimeTopologyBuilder() override ;
46 
47  using ReturnType = std::unique_ptr<FastTimeTopology>;
48 
50 
51 private:
52  // ----------member data ---------------------------
54  int type_;
56 };
57 
58 
60 
61  name_ = iConfig.getUntrackedParameter<std::string>("Name");
62  type_ = iConfig.getUntrackedParameter<int>("Type");
63  subdet_ = FastTime;
64 #ifdef EDM_ML_DEBUG
65  std::cout <<"constructing FastTimeTopology for " << name_ << " Type "
66  << type_ << std::endl;
67 #endif
68  setWhatProduced(this, name_);
69 }
70 
71 
73 
74 
75 //
76 // member functions
77 //
78 
79 // ------------ method called to produce the data ------------
82 
84  iRecord.get(pHGDC) ;
85  const FastTimeDDDConstants & hgdc = (*pHGDC);
86 
87 #ifdef EDM_ML_DEBUG
88  std::cout << "Create FastTimeTopology(hgdc,subdet,type)" << std::endl;
89 #endif
90  return std::make_unique<FastTimeTopology>(hgdc, subdet_, type_);
91 }
92 
FastTimeTopologyBuilder(const edm::ParameterSet &iP)
auto setWhatProduced(T *iThis, const es::Label &iLabel={})
Definition: ESProducer.h:124
T getUntrackedParameter(std::string const &, T const &) const
ForwardSubdetector
ProductT const & get(ESGetToken< ProductT, DepRecordT > const &iToken) const
#define DEFINE_FWK_EVENTSETUP_MODULE(type)
Definition: ModuleFactory.h:60
std::unique_ptr< FastTimeTopology > ReturnType
ReturnType produce(const IdealGeometryRecord &)