42 std::vector<std::string>
names = ps.getParameterNames();
43 for (std::vector<std::string>::iterator it = names.begin(); it != names.end(); ++it) {
45 if (!pset.exists(
"type"))
49 std::vector<InputTag>
tags = pset.getParameter<std::vector<InputTag>>(
"input");
52 if (
object ==
"SimTrack") {
60 produces<PCrossingFrame<SimTrack>>(
label);
61 consumes<std::vector<SimTrack>>(
tag);
62 LogInfo(
"MixingModule") <<
"Add PCrossingFrame<SimTrack> " <<
object <<
"s with InputTag= " << tag.encode()
63 <<
", label will be " <<
label;
67 else if (
object ==
"SimVertex") {
75 produces<PCrossingFrame<SimVertex>>(
label);
76 consumes<std::vector<SimVertex>>(
tag);
77 LogInfo(
"MixingModule") <<
"Add SimVertexContainer " <<
object <<
"s with InputTag= " << tag.encode()
78 <<
", label will be " <<
label;
82 else if (
object ==
"PCaloHit") {
85 std::vector<std::string>
subdets = pset.getParameter<std::vector<std::string>>(
"subdets");
86 for (
unsigned int ii = 0;
ii < subdets.size();
ii++) {
90 else if (tags.size() > 1)
94 branchesActivate(TypeID(
typeid(std::vector<PCaloHit>)).friendlyClassName(), subdets[
ii], tag, label);
95 produces<PCrossingFrame<PCaloHit>>(
label);
96 consumes<std::vector<PCaloHit>>(
tag);
97 LogInfo(
"MixingModule") <<
"Add PCrossingFrame<PCaloHit> " <<
object <<
"s with InputTag= " << tag.encode()
98 <<
", label will be " <<
label;
106 else if (
object ==
"PSimHit") {
109 std::vector<std::string> subdets = pset.getParameter<std::vector<std::string>>(
"subdets");
110 for (
unsigned int ii = 0;
ii < subdets.size();
ii++) {
112 if (tags.size() == 1)
115 else if (tags.size() > 1)
119 branchesActivate(TypeID(
typeid(std::vector<PSimHit>)).friendlyClassName(), subdets[
ii], tag, label);
120 produces<PCrossingFrame<PSimHit>>(
label);
121 consumes<std::vector<PSimHit>>(
tag);
122 LogInfo(
"MixingModule") <<
"Add PSimHitContainer " <<
object <<
"s with InputTag= " << tag.encode()
123 <<
", label will be " <<
label;
131 else if (
object ==
"HepMCProduct") {
140 produces<PCrossingFrame<edm::HepMCProduct>>(
label);
141 consumes<HepMCProduct>(
tag);
142 LogInfo(
"MixingModule") <<
"Add HepMCProduct " <<
object <<
"s with InputTag= " << tag.encode()
143 <<
", label will be " <<
label;
145 LogWarning(
"MixingModule") <<
"You did not mix a type of object(" <<
object <<
").";
std::vector< std::string > labCaloHit
const std::string names[nVars_]
std::vector< std::string > labSimHit
virtual void branchesActivate(const std::string &friendlyName, std::string subdet, InputTag &tag, std::string &label)
static const std::string subdets[7]