Main Page
Namespaces
Classes
Package Documentation
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Properties
Friends
Macros
Groups
Pages
SimMuon
Neutron
plugins
EmptyHepMCProducer.cc
Go to the documentation of this file.
1
// -*- C++ -*-
2
//
3
// Package: SimMuon/Neutron
4
// Class: EmptyHepMCProducer
5
//
14
//
15
// Original Author: Vadim Khotilovich
16
// Created: Mon Aug 09 19:11:42 CST 2010
17
//
18
//
19
20
#include "
FWCore/Framework/interface/Frameworkfwd.h
"
21
#include "
FWCore/Framework/interface/stream/EDProducer.h
"
22
#include "
FWCore/Framework/interface/ESHandle.h
"
23
24
#include "
FWCore/Framework/interface/Event.h
"
25
#include "
FWCore/Framework/interface/MakerMacros.h
"
26
27
#include "
FWCore/ParameterSet/interface/ParameterSet.h
"
28
29
#include "
SimDataFormats/GeneratorProducts/interface/HepMCProduct.h
"
30
31
class
EmptyHepMCProducer
:
public
edm::stream::EDProducer
<> {
32
public
:
33
explicit
EmptyHepMCProducer
(
const
edm::ParameterSet
&);
34
~EmptyHepMCProducer
()
override
{};
35
36
private
:
37
virtual
void
beginJob
();
38
void
produce
(
edm::Event
&,
const
edm::EventSetup
&)
override
;
39
virtual
void
endJob
();
40
};
41
42
EmptyHepMCProducer::EmptyHepMCProducer
(
const
edm::ParameterSet
&
iConfig
) { produces<edm::HepMCProduct>(); }
43
44
void
EmptyHepMCProducer::produce
(
edm::Event
&
iEvent
,
const
edm::EventSetup
& iSetup) {
45
// create an empty output collection
46
std::unique_ptr<edm::HepMCProduct> theOutput(
new
edm::HepMCProduct
());
47
//theOutput->addHepMCData(theEvent);
48
iEvent.
put
(
std::move
(theOutput));
49
}
50
51
void
EmptyHepMCProducer::beginJob
() {}
52
53
void
EmptyHepMCProducer::endJob
() {}
54
55
//define this as a plug-in
56
DEFINE_FWK_MODULE
(
EmptyHepMCProducer
);
edm::Event::put
OrphanHandle< PROD > put(std::unique_ptr< PROD > product)
Put a new product.
Definition:
Event.h:133
DEFINE_FWK_MODULE
#define DEFINE_FWK_MODULE(type)
Definition:
MakerMacros.h:16
Event.h
MakerMacros.h
EmptyHepMCProducer::produce
void produce(edm::Event &, const edm::EventSetup &) override
Definition:
EmptyHepMCProducer.cc:44
Frameworkfwd.h
ParameterSet.h
EmptyHepMCProducer::endJob
virtual void endJob()
Definition:
EmptyHepMCProducer.cc:53
EDProducer.h
iEvent
int iEvent
Definition:
GenABIO.cc:224
EmptyHepMCProducer::EmptyHepMCProducer
EmptyHepMCProducer(const edm::ParameterSet &)
Definition:
EmptyHepMCProducer.cc:42
eostools.move
def move
Definition:
eostools.py:511
ESHandle.h
edm::EventSetup
Definition:
EventSetup.h:59
HepMCProduct.h
EmptyHepMCProducer::beginJob
virtual void beginJob()
Definition:
EmptyHepMCProducer.cc:51
EmptyHepMCProducer
Definition:
EmptyHepMCProducer.cc:31
edm::stream::EDProducer
Definition:
EDProducer.h:36
edm::HepMCProduct
Definition:
HepMCProduct.h:21
EmptyHepMCProducer::~EmptyHepMCProducer
~EmptyHepMCProducer() override
Definition:
EmptyHepMCProducer.cc:34
edm::ParameterSet
Definition:
ParameterSet.h:47
edm::Event
Definition:
Event.h:73
iConfig
iConfig
Definition:
TSGFromPropagation.cc:56
Generated for CMSSW Reference Manual by
1.8.5