1 #ifndef FWCore_Framework_ESConsumesCollector_h 2 #define FWCore_Framework_ESConsumesCollector_h 42 class testEventsetupRecord;
45 class ESConsumesCollectorAdaptor;
46 class ESConsumesCollectorWithTagAdaptor;
52 std::unique_ptr<edm::eventsetup::impl::MayConsumeChooserCore> chooser)
60 std::unique_ptr<edm::eventsetup::impl::MayConsumeChooserCore>
chooser_;
73 template <
typename Product,
typename Record>
77 m_consumer->emplace_back(EventSetupRecordKey::makeKey<Record>(),
78 DataKey(DataKey::makeTypeTag<Product>(),
tag.data().c_str()),
86 template <
typename Product,
typename Record>
91 EventSetupRecordKey::makeKey<Record>(),
DataKey(DataKey::makeTypeTag<Product>(),
""),
"",
nullptr);
104 template <
typename Product,
typename Record,
typename Collector,
typename PTag>
108 iCollector->token() =
consumes(productTag.inputTag());
112 m_consumer->emplace_back(EventSetupRecordKey::makeKey<Record>(),
113 DataKey(DataKey::makeTypeTag<Product>(),
"@mayConsume"),
127 template <
typename RECORD>
139 template <
typename Product>
141 return consumesFrom<Product, RECORD>(
tag);
144 template <
typename Product>
146 return consumesFrom<Product, RECORD>();
149 template <
typename Product,
typename FromRecord,
typename Func,
typename PTag>
151 return registerMayConsume<Product, FromRecord>(
152 std::make_unique<eventsetup::impl::MayConsumeChooser<RECORD, Product, FromRecord, Func, PTag>>(
153 std::forward<Func>(
func)),
157 template <
typename Product,
typename FromRecord,
typename Func,
typename PTag>
159 token = mayConsumeFrom<Product, FromRecord>(std::forward<Func>(
func), productTag);
167 friend class ::testEventsetupRecord;
175 template <
typename TYPE,
typename REC>
177 return m_consumer->template consumesFrom<TYPE, REC>();
190 template <
typename TYPE,
typename REC>
192 return m_consumer->template consumesFrom<TYPE, REC>(m_tag);
ESConsumesCollector & setMayConsume(ESGetToken< Product, FromRecord > &token, Func &&func, PTag const &productTag)
edm::eventsetup::EventSetupRecordKey recordKey_
std::vector< ESConsumesInfoEntry > ESConsumesInfo
ESGetToken< TYPE, REC > consumes()
ESConsumesCollector(ESConsumesInfo *const iConsumer, unsigned int iTransitionID)
unsigned int m_transitionID
auto mayConsumeFrom(Func &&func, PTag const &productTag)
auto consumesFrom(ESInputTag const &tag)
auto consumes(ESInputTag const &tag)
ESConsumesCollector()=delete
ESConsumesCollectorWithTagAdaptor(ESConsumesCollector *iBase, ESInputTag iTag)
ESConsumesCollectorAdaptor(ESConsumesCollector *iBase)
auto registerMayConsume(std::unique_ptr< Collector > iCollector, PTag const &productTag)
ESConsumesCollector * m_consumer
edm::eventsetup::DataKey productKey_
ESGetToken< TYPE, REC > consumes()
std::unique_ptr< edm::eventsetup::impl::MayConsumeChooserCore > chooser_
ESConsumesCollectorT(ESConsumesInfo *const iConsumer, unsigned int iTransitionID)
ESConsumesCollector & operator=(ESConsumesCollector const &)=delete
edm::propagate_const< ESConsumesInfo * > m_consumer
ESConsumesCollectorAdaptor consumes()
ESConsumesCollector * m_consumer
ESConsumesInfoEntry(edm::eventsetup::EventSetupRecordKey const &iRecord, edm::eventsetup::DataKey const &iProduct, std::string moduleLabel, std::unique_ptr< edm::eventsetup::impl::MayConsumeChooserCore > chooser)