Main Page
Related Pages
Modules
Namespaces
Classes
Files
Examples
File List
File Members
art
art
test
Integration
testAssnsIter
AssnsIterProducer1_module.cc
Go to the documentation of this file.
1
////////////////////////////////////////////////////////////////////////
2
// Class: AssnsIterProducer1
3
// Plugin Type: producer (art v2_05_00)
4
// File: AssnsIterProducer1_module.cc
5
//
6
// Generated at Thu Dec 8 12:20:56 2016 by Saba Sehrish using cetskelgen
7
// from cetlib version v1_21_00.
8
////////////////////////////////////////////////////////////////////////
9
10
#include "
art/Framework/Core/EDProducer.h
"
11
#include "
art/Framework/Core/ModuleMacros.h
"
12
#include "
art/Framework/Principal/Event.h
"
13
#include "
art/Framework/Principal/Handle.h
"
14
#include "
art/Framework/Principal/Run.h
"
15
#include "
art/Framework/Principal/SubRun.h
"
16
#include "
canvas/Persistency/Common/Assns.h
"
17
#include "
canvas/Persistency/Common/Ptr.h
"
18
#include "
canvas/Utilities/InputTag.h
"
19
#include "
fhiclcpp/ParameterSet.h
"
20
#include "
messagefacility/MessageLogger/MessageLogger.h
"
21
22
namespace
lartest
{
23
class
AssnsIterProducer1
;
24
}
25
26
using
lartest::AssnsIterProducer1
;
27
28
class
lartest::AssnsIterProducer1
:
public
art::EDProducer
{
29
public
:
30
typedef
std::vector<int>
intvec_t
;
31
typedef
std::vector<std::string>
strvec_t
;
32
typedef
std::vector<float>
floatvec_t
;
33
34
explicit
AssnsIterProducer1
(
fhicl::ParameterSet
const
&
p
);
35
// The compiler-generated destructor is fine for non-base
36
// classes without bare pointers or other resource use.
37
38
// Plugins should not be copied or assigned.
39
AssnsIterProducer1
(
AssnsIterProducer1
const
&) =
delete
;
40
AssnsIterProducer1
(
AssnsIterProducer1
&&) =
delete
;
41
AssnsIterProducer1
&
operator=
(
AssnsIterProducer1
const
&) =
delete
;
42
AssnsIterProducer1
&
operator=
(
AssnsIterProducer1
&&) =
delete
;
43
44
// Required functions.
45
void
produce
(
art::Event
&
e
)
override
;
46
47
private
:
48
std::string
fInputLabel
;
49
};
50
51
AssnsIterProducer1::AssnsIterProducer1
(
fhicl::ParameterSet
const
&
p
)
52
:
EDProducer
{p},
fInputLabel
(
p
.get<
std::string
>(
"input_label"
))
53
{
54
produces<intvec_t>();
55
produces<strvec_t>();
56
produces<floatvec_t>();
57
}
58
59
void
60
AssnsIterProducer1::produce
(
art::Event
&
e
)
61
{
62
auto
vs = std::make_unique<strvec_t>(
63
strvec_t
{
"one"
,
"one-a"
,
"two"
,
"two-a"
,
"three"
,
"three-a"
});
64
auto
vi = std::make_unique<intvec_t>(
intvec_t
{1, 2, 3});
65
auto
vf =
66
std::make_unique<floatvec_t>(
floatvec_t
{1.0, 1.1, 2.0, 2.1, 3.0, 3.1});
67
68
e.
put
(std::move(vs));
69
e.
put
(std::move(vi));
70
e.
put
(std::move(vf));
71
}
72
73
DEFINE_ART_MODULE
(
AssnsIterProducer1
)
Assns.h
lartest::AssnsIterProducer1::intvec_t
std::vector< int > intvec_t
Definition:
AssnsIterProducer1_module.cc:30
Handle.h
string
std::string string
Definition:
nybbler.cc:12
art::EDProducer::EDProducer
EDProducer()=default
MessageLogger.h
ParameterSet.h
lartest::AssnsIterProducer1::strvec_t
std::vector< std::string > strvec_t
Definition:
AssnsIterProducer1_module.cc:31
lartest::AssnsIterProducer1::fInputLabel
std::string fInputLabel
Definition:
AssnsIterProducer1_module.cc:48
e
const double e
Definition:
gUpMuFluxGen.cxx:165
DEFINE_ART_MODULE
#define DEFINE_ART_MODULE(klass)
Definition:
ModuleMacros.h:68
lartest::AssnsIterProducer1::floatvec_t
std::vector< float > floatvec_t
Definition:
AssnsIterProducer1_module.cc:32
Ptr.h
SubRun.h
lartest::AssnsIterProducer1::produce
void produce(art::Event &e) override
Definition:
AssnsIterProducer1_module.cc:60
ModuleMacros.h
lartest::AssnsIterProducer1::AssnsIterProducer1
AssnsIterProducer1(fhicl::ParameterSet const &p)
Definition:
AssnsIterProducer1_module.cc:51
art::EDProducer
Definition:
EDProducer.h:15
EDProducer.h
test.p
p
Definition:
test.py:228
art::Event
Definition:
Event.h:40
lartest
Definition:
AssnsIterProducer1_module.cc:22
InputTag.h
lartest::AssnsIterProducer1
Definition:
AssnsIterProducer1_module.cc:28
Event.h
art::DataViewImpl::put
ProductID put(std::unique_ptr< PROD > &&edp, FullSemantic< Level::Run > const semantic)
Definition:
DataViewImpl.h:692
lartest::AssnsIterProducer1::operator=
AssnsIterProducer1 & operator=(AssnsIterProducer1 const &)=delete
Run.h
fhicl::ParameterSet
Definition:
ParameterSet.h:34
Generated by
1.8.11