CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Public Member Functions | Private Attributes
CosmicMuonProducer Class Reference

#include <CosmicMuonProducer.h>

Inheritance diagram for CosmicMuonProducer:
edm::stream::EDProducer<> edm::stream::EDProducerBase edm::ProducerBase edm::EDConsumerBase edm::ProductRegistryHelper

Public Member Functions

 CosmicMuonProducer (const edm::ParameterSet &)
 
virtual void produce (edm::Event &, const edm::EventSetup &) override
 
 ~CosmicMuonProducer ()
 
- Public Member Functions inherited from edm::stream::EDProducer<>
 EDProducer ()=default
 
- Public Member Functions inherited from edm::stream::EDProducerBase
 EDProducerBase ()
 
ModuleDescription const & moduleDescription () const
 
virtual ~EDProducerBase ()
 
- Public Member Functions inherited from edm::ProducerBase
 ProducerBase ()
 
void registerProducts (ProducerBase *, ProductRegistry *, ModuleDescription const &)
 
std::function< void(BranchDescription
const &)> 
registrationCallback () const
 used by the fwk to register list of products More...
 
virtual ~ProducerBase ()
 
- Public Member Functions inherited from edm::EDConsumerBase
 EDConsumerBase ()
 
ProductHolderIndexAndSkipBit indexFrom (EDGetToken, BranchType, TypeID const &) const
 
void itemsMayGet (BranchType, std::vector< ProductHolderIndexAndSkipBit > &) const
 
void itemsToGet (BranchType, std::vector< ProductHolderIndexAndSkipBit > &) const
 
std::vector
< ProductHolderIndexAndSkipBit >
const & 
itemsToGetFromEvent () const
 
void labelsForToken (EDGetToken iToken, Labels &oLabels) const
 
void modulesDependentUpon (const std::string &iProcessName, std::vector< const char * > &oModuleLabels) const
 
bool registeredToConsume (ProductHolderIndex, bool, BranchType) const
 
bool registeredToConsumeMany (TypeID const &, BranchType) const
 
void updateLookup (BranchType iBranchType, ProductHolderIndexHelper const &)
 
virtual ~EDConsumerBase ()
 

Private Attributes

edm::EDGetTokenT< edm::View
< TrajectorySeed > > 
theSeedCollectionToken
 
MuonServiceProxytheService
 the event setup proxy, it takes care the services update More...
 
MuonTrackFindertheTrackFinder
 

Additional Inherited Members

- Public Types inherited from edm::stream::EDProducer<>
typedef CacheContexts< T...> CacheTypes
 
typedef CacheTypes::GlobalCache GlobalCache
 
typedef AbilityChecker< T...> HasAbility
 
typedef
CacheTypes::LuminosityBlockCache 
LuminosityBlockCache
 
typedef
LuminosityBlockContextT
< LuminosityBlockCache,
RunCache, GlobalCache
LuminosityBlockContext
 
typedef
CacheTypes::LuminosityBlockSummaryCache 
LuminosityBlockSummaryCache
 
typedef CacheTypes::RunCache RunCache
 
typedef RunContextT< RunCache,
GlobalCache
RunContext
 
typedef CacheTypes::RunSummaryCache RunSummaryCache
 
- Public Types inherited from edm::stream::EDProducerBase
typedef EDProducerAdaptorBase ModuleType
 
- Public Types inherited from edm::ProducerBase
typedef
ProductRegistryHelper::TypeLabelList 
TypeLabelList
 
- Static Public Member Functions inherited from edm::stream::EDProducerBase
static const std::string & baseType ()
 
static void fillDescriptions (ConfigurationDescriptions &descriptions)
 
static void prevalidate (ConfigurationDescriptions &descriptions)
 
- Protected Member Functions inherited from edm::ProducerBase
void callWhenNewProductsRegistered (std::function< void(BranchDescription const &)> const &func)
 
- Protected Member Functions inherited from edm::EDConsumerBase
template<typename ProductType , BranchType B = InEvent>
EDGetTokenT< ProductType > consumes (edm::InputTag const &tag)
 
EDGetToken consumes (const TypeToGet &id, edm::InputTag const &tag)
 
template<BranchType B>
EDGetToken consumes (TypeToGet const &id, edm::InputTag const &tag)
 
ConsumesCollector consumesCollector ()
 Use a ConsumesCollector to gather consumes information from helper functions. More...
 
template<typename ProductType , BranchType B = InEvent>
void consumesMany ()
 
void consumesMany (const TypeToGet &id)
 
template<BranchType B>
void consumesMany (const TypeToGet &id)
 
template<typename ProductType , BranchType B = InEvent>
EDGetTokenT< ProductType > mayConsume (edm::InputTag const &tag)
 
EDGetToken mayConsume (const TypeToGet &id, edm::InputTag const &tag)
 
template<BranchType B>
EDGetToken mayConsume (const TypeToGet &id, edm::InputTag const &tag)
 

Detailed Description

Description: CosmicMuonProducer for muons from cosmic rays

Implementation:

Original Author: Chang Liu Created: Tue Jun 13 02:46:17 CEST 2006

Definition at line 15 of file CosmicMuonProducer.h.

Constructor & Destructor Documentation

CosmicMuonProducer::CosmicMuonProducer ( const edm::ParameterSet iConfig)
explicit

Definition at line 42 of file CosmicMuonProducer.cc.

References edm::ParameterSet::getParameter(), MuonServiceProxy_cff::MuonServiceProxy, and AlCaHLTBitMon_QueryRunRegistry::string.

43 {
44  ParameterSet tbpar = iConfig.getParameter<ParameterSet>("TrajectoryBuilderParameters");
45 
46  theSeedCollectionToken =consumes<edm::View<TrajectorySeed> >( iConfig.getParameter<std::string>("MuonSeedCollectionLabel"));
47 
48  // service parameters
49  ParameterSet serviceParameters = iConfig.getParameter<ParameterSet>("ServiceParameters");
50 
51  // TrackLoader parameters
52  ParameterSet trackLoaderParameters = iConfig.getParameter<ParameterSet>("TrackLoaderParameters");
53 
54  // the services
55 
57 
58  theService = new MuonServiceProxy(serviceParameters);
60  new MuonTrackLoader(trackLoaderParameters,iC, theService));
61 
62  produces<reco::TrackCollection>();
63  produces<TrackingRecHitCollection>();
64  produces<reco::TrackExtraCollection>();
65  produces<std::vector<Trajectory> >();
66  produces<TrajTrackAssociationCollection>();
67 
68 }
T getParameter(std::string const &) const
ConsumesCollector consumesCollector()
Use a ConsumesCollector to gather consumes information from helper functions.
MuonServiceProxy * theService
the event setup proxy, it takes care the services update
MuonTrackFinder * theTrackFinder
edm::EDGetTokenT< edm::View< TrajectorySeed > > theSeedCollectionToken
CosmicMuonProducer::~CosmicMuonProducer ( )

Definition at line 71 of file CosmicMuonProducer.cc.

72 {
73  if (theService) delete theService;
74  if (theTrackFinder) delete theTrackFinder;
75 }
MuonServiceProxy * theService
the event setup proxy, it takes care the services update
MuonTrackFinder * theTrackFinder

Member Function Documentation

void CosmicMuonProducer::produce ( edm::Event iEvent,
const edm::EventSetup iSetup 
)
overridevirtual

Implements edm::stream::EDProducerBase.

Definition at line 80 of file CosmicMuonProducer.cc.

References edm::Event::getByToken(), and edm::EventBase::id().

81 {
82  LogInfo("CosmicMuonProducer") << "Analyzing event number: " << iEvent.id();
83 
85  iEvent.getByToken(theSeedCollectionToken,seeds);
86 
87  // Update the services
88  theService->update(iSetup);
89  theTrackFinder->reconstruct(seeds,iEvent);
90 }
bool getByToken(EDGetToken token, Handle< PROD > &result) const
Definition: Event.h:434
MuonServiceProxy * theService
the event setup proxy, it takes care the services update
MuonTrackFinder * theTrackFinder
edm::EventID id() const
Definition: EventBase.h:56
edm::EDGetTokenT< edm::View< TrajectorySeed > > theSeedCollectionToken
edm::OrphanHandle< reco::TrackCollection > reconstruct(const edm::Handle< edm::View< TrajectorySeed > > &, edm::Event &)
reconstruct standalone tracks starting from a collection of seeds

Member Data Documentation

edm::EDGetTokenT<edm::View<TrajectorySeed> > CosmicMuonProducer::theSeedCollectionToken
private

Definition at line 28 of file CosmicMuonProducer.h.

MuonServiceProxy* CosmicMuonProducer::theService
private

the event setup proxy, it takes care the services update

Definition at line 27 of file CosmicMuonProducer.h.

MuonTrackFinder* CosmicMuonProducer::theTrackFinder
private

Definition at line 24 of file CosmicMuonProducer.h.