1 #ifndef FWCore_Framework_stream_ProducingModuleAdaptorBase_h 2 #define FWCore_Framework_stream_ProducingModuleAdaptorBase_h 25 #include <unordered_map> 45 class ModuleCallingContext;
46 class ProductResolverIndexHelper;
48 class PreallocationConfiguration;
49 class ProductResolverIndexAndSkipBit;
50 class ProductRegistry;
51 class ThinnedAssociationsHelper;
54 template<
typename T>
class ModuleHolderT;
59 class ProducingModuleAdaptorBase
79 void itemsToGet(
BranchType, std::vector<ProductResolverIndexAndSkipBit>&)
const;
80 void itemsMayGet(
BranchType, std::vector<ProductResolverIndexAndSkipBit>&)
const;
81 std::vector<ProductResolverIndexAndSkipBit>
const& itemsToGetFrom(
BranchType)
const;
85 bool iPrefetchMayGet);
87 void modulesWhoseProductsAreConsumed(std::vector<ModuleDescription const*>&
modules,
89 std::map<std::string, ModuleDescription const*>
const& labelsToDesc,
92 void convertCurrentProcessAlias(
std::string const& processName);
94 std::vector<ConsumesInfo> consumesInfo()
const;
96 void resolvePutIndicies(
BranchType iBranchType,
97 std::unordered_multimap<std::string, edm::ProductResolverIndex>
const& iIndicies,
100 std::vector<edm::ProductResolverIndex>
const& indiciesForPutProducts(
BranchType iBranchType)
const;
104 for(
auto&
m: m_streamModules) {
106 m->setModuleDescriptionPtr(&moduleDescription_);
111 iRun.
commit_(m_streamModules[0]->indiciesForPutProducts(
InRun));
114 iLumi.
commit_(m_streamModules[0]->indiciesForPutProducts(
InLumi));
116 template<
typename L,
typename I>
118 iEvent.
commit_(m_streamModules[0]->indiciesForPutProducts(
InEvent), iList,iID);
122 return m_streamModules[0];
130 virtual void setupStreamModules() = 0;
132 virtual void doEndJob() = 0;
147 void doStreamBeginLuminosityBlock(
StreamID id,
152 void doStreamEndLuminosityBlock(
StreamID id,
170 void doPreForkReleaseResources();
171 void doPostForkReacquireResources(
unsigned int iChildIndex,
unsigned int iNumberOfChildren);
174 void doRespondToOpenInputFile(
FileBlock const&
fb);
175 void doRespondToCloseInputFile(
FileBlock const& fb);
181 moduleDescription_ = md;
ModuleDescription moduleDescription_
void commit(Event &iEvent, L *iList, I *iID)
void registerProductsAndCallbacks(ProductRegistry *iReg) override
void commit_(std::vector< edm::ProductResolverIndex > const &iShouldPut, std::vector< BranchID > *previousParentage=0, ParentageID *previousParentageId=0)
const EDConsumerBase * consumer()
void commit_(std::vector< edm::ProductResolverIndex > const &iShouldPut)
void setModuleDescription(ModuleDescription const &md)
void createStreamModules(F iFunc)
const std::complex< double > I
const ModuleDescription & moduleDescription() const
void commit(LuminosityBlock &iLumi)
std::vector< T * > m_streamModules
static uInt32 F(BLOWFISH_CTX *ctx, uInt32 x)
void commit_(std::vector< edm::ProductResolverIndex > const &iShouldPut)