File indexing completed on 2025-04-22 06:27:18
0001
0002
0003
0004
0005
0006
0007
0008
0009
0010
0011
0012
0013
0014 #include <cassert>
0015
0016
0017 #include "FWCore/Framework/interface/one/OutputModuleBase.h"
0018
0019 #include "DataFormats/Common/interface/Handle.h"
0020 #include "DataFormats/Common/interface/ThinnedAssociation.h"
0021 #include "DataFormats/Common/interface/EndPathStatus.h"
0022 #include "DataFormats/Provenance/interface/ProductDescription.h"
0023 #include "DataFormats/Provenance/interface/BranchKey.h"
0024 #include "DataFormats/Provenance/interface/ProductRegistry.h"
0025 #include "DataFormats/Provenance/interface/ThinnedAssociationsHelper.h"
0026 #include "FWCore/Framework/interface/EventForOutput.h"
0027 #include "FWCore/Framework/interface/EventPrincipal.h"
0028 #include "FWCore/Framework/src/insertSelectedProcesses.h"
0029 #include "FWCore/Framework/interface/LuminosityBlockForOutput.h"
0030 #include "FWCore/Framework/interface/ProcessBlockForOutput.h"
0031 #include "FWCore/Framework/interface/RunForOutput.h"
0032 #include "FWCore/Framework/src/OutputModuleDescription.h"
0033 #include "FWCore/Framework/interface/TriggerNamesService.h"
0034 #include "FWCore/Framework/src/EventSignalsSentry.h"
0035 #include "FWCore/Framework/interface/PreallocationConfiguration.h"
0036 #include "FWCore/ParameterSet/interface/ConfigurationDescriptions.h"
0037 #include "FWCore/ParameterSet/interface/ParameterSet.h"
0038 #include "FWCore/ParameterSet/interface/ParameterSetDescription.h"
0039 #include "FWCore/ServiceRegistry/interface/Service.h"
0040 #include "FWCore/Utilities/interface/DebugMacros.h"
0041 #include "FWCore/Reflection/interface/DictionaryTools.h"
0042
0043 namespace edm {
0044 namespace one {
0045
0046
0047 OutputModuleBase::OutputModuleBase(ParameterSet const& pset) : core::OutputModuleCore(pset) {}
0048
0049 void OutputModuleBase::configure(OutputModuleDescription const& desc) { core::OutputModuleCore::configure(desc); }
0050
0051 SharedResourcesAcquirer OutputModuleBase::createAcquirer() {
0052 return SharedResourcesAcquirer{
0053 std::vector<std::shared_ptr<SerialTaskQueue>>(1, std::make_shared<SerialTaskQueue>())};
0054 }
0055
0056 void OutputModuleBase::doPreallocate(PreallocationConfiguration const& iPC) {
0057 core::OutputModuleCore::doPreallocate_(iPC);
0058 }
0059
0060 void OutputModuleBase::doBeginJob() {
0061 resourcesAcquirer_ = createAcquirer();
0062 core::OutputModuleCore::doBeginJob_();
0063 }
0064
0065 bool OutputModuleBase::doEvent(EventTransitionInfo const& info,
0066 ActivityRegistry* act,
0067 ModuleCallingContext const* mcc) {
0068 { core::OutputModuleCore::doEvent_(info, act, mcc); }
0069 if (remainingEvents_ > 0) {
0070 --remainingEvents_;
0071 }
0072 return true;
0073 }
0074 }
0075 }