CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
TCMETProducer.cc
Go to the documentation of this file.
1 // -*- C++ -*-
2 //
3 // Package: METProducers
4 // Class: TCMETProducer
5 //
6 //
7 
8 //____________________________________________________________________________||
10 
13 
15 
16 #include <string.h>
17 
18 //____________________________________________________________________________||
19 namespace cms
20 {
21 
22 //____________________________________________________________________________||
24  {
25  std::string alias = iConfig.exists("alias") ? iConfig.getParameter<std::string>("alias") : "";
26 
27  produces<reco::METCollection>().setBranchAlias(alias);
28 
30  }
31 
32 //____________________________________________________________________________||
34  {
35  std::auto_ptr<reco::METCollection> tcmetcoll;
36  tcmetcoll.reset(new reco::METCollection);
37  tcmetcoll->push_back(tcMetAlgo_.CalculateTCMET(event, setup));
38  event.put(tcmetcoll);
39  }
40 
41 //____________________________________________________________________________||
43 }
44 
45 //____________________________________________________________________________||
T getParameter(std::string const &) const
reco::MET CalculateTCMET(edm::Event &event, const edm::EventSetup &setup)
Definition: TCMETAlgo.cc:179
TCMETAlgo tcMetAlgo_
Definition: TCMETProducer.h:44
#define DEFINE_FWK_MODULE(type)
Definition: MakerMacros.h:17
bool exists(std::string const &parameterName) const
checks if a parameter exists
std::vector< reco::MET > METCollection
collection of MET objects
Definition: METCollection.h:23
TCMETProducer(const edm::ParameterSet &)
ConsumesCollector consumesCollector()
Use a ConsumesCollector to gather consumes information from helper functions.
How EventSelector::AcceptEvent() decides whether to accept an event for output otherwise it is excluding the probing of A single or multiple positive and the trigger will pass if any such matching triggers are PASS or EXCEPTION[A criterion thatmatches no triggers at all is detected and causes a throw.] A single negative with an expectation of appropriate bit checking in the decision and the trigger will pass if any such matching triggers are FAIL or EXCEPTION A wildcarded negative criterion that matches more than one trigger in the trigger but the state exists so we define the behavior If all triggers are the negative crieriion will lead to accepting the event(this again matches the behavior of"!*"before the partial wildcard feature was incorporated).The per-event"cost"of each negative criterion with multiple relevant triggers is about the same as!*was in the past
virtual void produce(edm::Event &, const edm::EventSetup &) override
void configure(const edm::ParameterSet &iConfig, edm::ConsumesCollector &&iConsumesCollector)
Definition: TCMETAlgo.cc:65