CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
Functions
L1GtBoardMapsTrivialProducer.cc File Reference
#include "L1TriggerConfig/L1GtConfigProducers/interface/L1GtBoardMapsTrivialProducer.h"
#include <memory>
#include "boost/shared_ptr.hpp"
#include <string>
#include "FWCore/Utilities/interface/EDMException.h"
#include "FWCore/Framework/interface/ModuleFactory.h"
#include "FWCore/Framework/interface/ESHandle.h"
#include "CondFormats/L1TObjects/interface/L1GtFwd.h"

Go to the source code of this file.

Functions

std::vector< L1GtObjectchInputObjects (const std::vector< std::string > &chInputStrings)
 

Function Documentation

std::vector<L1GtObject> chInputObjects ( const std::vector< std::string > &  chInputStrings)

Definition at line 39 of file L1GtBoardMapsTrivialProducer.cc.

References BPTX, CenJet, ETM, ETT, edm::hlt::Exception, ForJet, GtExternal, HfBitCounts, HfRingEtSums, HTM, HTT, IsoEG, JetCounts, Mu, NoIsoEG, VarParsing::obj, TauJet, and TechTrig.

Referenced by L1GtBoardMapsTrivialProducer::L1GtBoardMapsTrivialProducer().

41 {
42  std::vector<L1GtObject> chInputObjectsV;
43  chInputObjectsV.reserve(chInputStrings.size());
44 
46 
47  for (std::vector<std::string>::const_iterator itObj =
48  chInputStrings.begin(); itObj != chInputStrings.end(); ++itObj) {
49 
50  if ((*itObj) == "Mu") {
51  obj = Mu;
52  }
53  else if ((*itObj) == "NoIsoEG") {
54  obj = NoIsoEG;
55  }
56  else if ((*itObj) == "IsoEG") {
57  obj = IsoEG;
58  }
59  else if ((*itObj) == "CenJet") {
60  obj = CenJet;
61  }
62  else if ((*itObj) == "ForJet") {
63  obj = ForJet;
64  }
65  else if ((*itObj) == "TauJet") {
66  obj = TauJet;
67  }
68  else if ((*itObj) == "ETM") {
69  obj = ETM;
70  }
71  else if ((*itObj) == "ETT") {
72  obj = ETT;
73  }
74  else if ((*itObj) == "HTT") {
75  obj = HTT;
76  }
77  else if ((*itObj) == "HTM") {
78  obj = HTM;
79  }
80  else if ((*itObj) == "JetCounts") {
81  obj = JetCounts;
82  }
83  else if ((*itObj) == "HfBitCounts") {
84  obj = HfBitCounts;
85  }
86  else if ((*itObj) == "HfRingEtSums") {
87  obj = HfRingEtSums;
88  }
89  else if ((*itObj) == "TechTrig") {
90  obj = TechTrig;
91  }
92  else if ((*itObj) == "BPTX") {
93  obj = BPTX;
94  }
95  else if ((*itObj) == "GtExternal") {
96  obj = GtExternal;
97  }
98  else {
99  throw cms::Exception("Configuration")
100  << "\nError: no such L1 GT object: " << (*itObj) << "\n"
101  << "\n Can not define the mapping of the L1 GT boards. \n"
102  << std::endl;
103 
104  }
105 
106  chInputObjectsV.push_back(obj);
107  }
108 
109  return chInputObjectsV;
110 }
tuple obj
Example code starts here #.
Definition: VarParsing.py:655
L1GtObject
GT objects.