CMS 3D CMS Logo

List of all members | Public Member Functions | Private Attributes
MultiRecHitCollectorESProducer Class Reference

#include <MultiRecHitCollectorESProducer.h>

Inheritance diagram for MultiRecHitCollectorESProducer:
edm::ESProducer edm::ESProxyFactoryProducer edm::eventsetup::DataProxyProvider

Public Member Functions

 MultiRecHitCollectorESProducer (const edm::ParameterSet &iConfig)
 
std::unique_ptr< MultiRecHitCollectorproduce (const MultiRecHitRecord &)
 
void setConf (const edm::ParameterSet &conf)
 
 ~MultiRecHitCollectorESProducer () override
 
- Public Member Functions inherited from edm::ESProducer
 ESProducer ()
 
 ESProducer (const ESProducer &)=delete
 
ESProxyIndex const * getTokenIndices (unsigned int iIndex) const
 
ESProducer const & operator= (const ESProducer &)=delete
 
template<typename Record >
void updateFromMayConsumes (unsigned int iIndex, const Record &iRecord)
 
void updateLookup (eventsetup::ESRecordsToProxyIndices const &) final
 
 ~ESProducer ()(false) override
 
- Public Member Functions inherited from edm::ESProxyFactoryProducer
 ESProxyFactoryProducer ()
 
 ESProxyFactoryProducer (const ESProxyFactoryProducer &)=delete
 
const ESProxyFactoryProduceroperator= (const ESProxyFactoryProducer &)=delete
 
 ~ESProxyFactoryProducer () noexcept(false) override
 
- Public Member Functions inherited from edm::eventsetup::DataProxyProvider
void createKeyedProxies (EventSetupRecordKey const &key, unsigned int nConcurrentIOVs)
 
 DataProxyProvider ()
 
 DataProxyProvider (const DataProxyProvider &)=delete
 
const ComponentDescriptiondescription () const
 
void fillRecordsNotAllowingConcurrentIOVs (std::set< EventSetupRecordKey > &recordsNotAllowingConcurrentIOVs) const
 
virtual void initConcurrentIOVs (EventSetupRecordKey const &key, unsigned int nConcurrentIOVs)
 
bool isUsingRecord (const EventSetupRecordKey &key) const
 
KeyedProxieskeyedProxies (const EventSetupRecordKey &iRecordKey, unsigned int iovIndex=0)
 
const DataProxyProvideroperator= (const DataProxyProvider &)=delete
 
void setAppendToDataLabel (const edm::ParameterSet &)
 
void setDescription (const ComponentDescription &iDescription)
 
std::set< EventSetupRecordKeyusingRecords () const
 
virtual ~DataProxyProvider () noexcept(false)
 

Private Attributes

edm::ParameterSet conf_
 

Additional Inherited Members

- Static Public Member Functions inherited from edm::eventsetup::DataProxyProvider
static void prevalidate (ConfigurationDescriptions &)
 
- Protected Types inherited from edm::ESProxyFactoryProducer
using EventSetupRecordKey = eventsetup::EventSetupRecordKey
 
- Protected Types inherited from edm::eventsetup::DataProxyProvider
using KeyedProxiesVector = std::vector< std::pair< DataKey, std::shared_ptr< DataProxy >>>
 
- Protected Member Functions inherited from edm::ESProducer
template<typename T >
auto setWhatProduced (T *iThis, const es::Label &iLabel={})
 
template<typename T >
auto setWhatProduced (T *iThis, const char *iLabel)
 
template<typename T >
auto setWhatProduced (T *iThis, const std::string &iLabel)
 
template<typename T , typename TDecorator >
auto setWhatProduced (T *iThis, const TDecorator &iDec, const es::Label &iLabel={})
 
template<typename T , typename TReturn , typename TRecord >
auto setWhatProduced (T *iThis, TReturn(T::*iMethod)(const TRecord &), const es::Label &iLabel={})
 
template<typename T , typename TReturn , typename TRecord , typename TArg >
ESConsumesCollectorT< TRecord > setWhatProduced (T *iThis, TReturn(T::*iMethod)(const TRecord &), const TArg &iDec, const es::Label &iLabel={})
 
- Protected Member Functions inherited from edm::ESProxyFactoryProducer
template<class TFactory >
void registerFactory (std::unique_ptr< TFactory > iFactory, const std::string &iLabel=std::string())
 
virtual void registerFactoryWithKey (const EventSetupRecordKey &iRecord, std::unique_ptr< eventsetup::ProxyFactoryBase > iFactory, const std::string &iLabel=std::string())
 
KeyedProxiesVector registerProxies (const EventSetupRecordKey &, unsigned int iovIndex) override
 
- Protected Member Functions inherited from edm::eventsetup::DataProxyProvider
template<class T >
void usingRecord ()
 
void usingRecordWithKey (const EventSetupRecordKey &key)
 

Detailed Description

Definition at line 19 of file MultiRecHitCollectorESProducer.h.

Constructor & Destructor Documentation

MultiRecHitCollectorESProducer::MultiRecHitCollectorESProducer ( const edm::ParameterSet iConfig)

Definition at line 23 of file MultiRecHitCollectorESProducer.cc.

References edm::ParameterSet::getParameter(), and AlCaHLTBitMon_QueryRunRegistry::string.

23  {
24  std::string myname = iConfig.getParameter<std::string>("ComponentName");
25  setConf(iConfig);
26  setWhatProduced(this, myname);
27 }
void setConf(const edm::ParameterSet &conf)
T getParameter(std::string const &) const
auto setWhatProduced(T *iThis, const es::Label &iLabel={})
Definition: ESProducer.h:138
MultiRecHitCollectorESProducer::~MultiRecHitCollectorESProducer ( )
override

Definition at line 29 of file MultiRecHitCollectorESProducer.cc.

29 {}

Member Function Documentation

std::unique_ptr< MultiRecHitCollector > MultiRecHitCollectorESProducer::produce ( const MultiRecHitRecord iRecord)

Definition at line 31 of file MultiRecHitCollectorESProducer.cc.

References debug, edm::eventsetup::DependentRecordImplementation< RecordT, ListT >::get(), edm::eventsetup::DependentRecordImplementation< RecordT, ListT >::getRecord(), HLT_2018_cff::measurementTrackerName, ALCARECOPromptCalibProdSiPixelAli0T_cff::mode, edm::ESHandle< T >::product(), and AlCaHLTBitMon_QueryRunRegistry::string.

31  {
32  std::string mode = "Grouped";
33  if (conf_.getParameter<std::string>("Mode") == "Simple")
34  mode = "Simple";
35 
36  std::string mrhupdator = conf_.getParameter<std::string>("MultiRecHitUpdator");
37  std::string propagatorAlongName = conf_.getParameter<std::string>("propagatorAlong");
38  std::string estimatorName = conf_.getParameter<std::string>("estimator");
40  bool debug = conf_.getParameter<bool>("Debug");
41 
43  iRecord.get(mrhupdator, mrhuhandle);
44  ESHandle<Propagator> propagatorhandle;
45  iRecord.getRecord<CkfComponentsRecord>().getRecord<TrackingComponentsRecord>().get(propagatorAlongName,
46  propagatorhandle);
48  iRecord.getRecord<CkfComponentsRecord>().getRecord<TrackingComponentsRecord>().get(estimatorName, estimatorhandle);
49  ESHandle<MeasurementTracker> measurementhandle;
50  iRecord.getRecord<CkfComponentsRecord>().get(measurementTrackerName, measurementhandle);
51  ESHandle<TrackerTopology> trackerTopologyHandle;
52  iRecord.getRecord<CkfComponentsRecord>().getRecord<TrackerTopologyRcd>().get(trackerTopologyHandle);
53 
54  if (mode == "Grouped") {
55  std::string propagatorOppositeName = conf_.getParameter<std::string>("propagatorOpposite");
56  ESHandle<Propagator> propagatorOppositehandle;
57  iRecord.getRecord<CkfComponentsRecord>().getRecord<TrackingComponentsRecord>().get(propagatorOppositeName,
58  propagatorOppositehandle);
59  return std::make_unique<GroupedDAFHitCollector>(measurementhandle.product(),
60  mrhuhandle.product(),
61  estimatorhandle.product(),
62  propagatorhandle.product(),
63  propagatorOppositehandle.product(),
64  debug);
65  } else {
66  return std::make_unique<SimpleDAFHitCollector>(trackerTopologyHandle.product(),
67  measurementhandle.product(),
68  mrhuhandle.product(),
69  estimatorhandle.product(),
70  propagatorhandle.product(),
71  debug);
72  }
73 }
T getParameter(std::string const &) const
ProductT const & get(ESGetToken< ProductT, DepRecordT > const &iToken) const
#define debug
Definition: HDRShower.cc:19
T const * product() const
Definition: ESHandle.h:86
void MultiRecHitCollectorESProducer::setConf ( const edm::ParameterSet conf)
inline

Definition at line 26 of file MultiRecHitCollectorESProducer.h.

References conf_.

26 { conf_ = conf; }

Member Data Documentation

edm::ParameterSet MultiRecHitCollectorESProducer::conf_
private

Definition at line 29 of file MultiRecHitCollectorESProducer.h.

Referenced by setConf().