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
CRackSeedGenerator Class Reference

#include <CRackSeedGenerator.h>

Inheritance diagram for CRackSeedGenerator:
edm::EDProducer edm::ProducerBase edm::EDConsumerBase edm::ProductRegistryHelper

Public Member Functions

 CRackSeedGenerator (const edm::ParameterSet &conf)
 
virtual void produce (edm::Event &e, const edm::EventSetup &c) override
 
virtual ~CRackSeedGenerator ()
 
- Public Member Functions inherited from edm::EDProducer
 EDProducer ()
 
ModuleDescription const & moduleDescription () const
 
virtual ~EDProducer ()
 
- 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
std::vector< ConsumesInfoconsumesInfo () const
 
 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
 
void modulesWhoseProductsAreConsumed (std::vector< ModuleDescription const * > &modules, ProductRegistry const &preg, std::map< std::string, ModuleDescription const * > const &labelsToDesc, std::string const &processName) const
 
bool registeredToConsume (ProductHolderIndex, bool, BranchType) const
 
bool registeredToConsumeMany (TypeID const &, BranchType) const
 
void updateLookup (BranchType iBranchType, ProductHolderIndexHelper const &)
 
virtual ~EDConsumerBase ()
 

Private Attributes

edm::ParameterSet conf_
 
SeedGeneratorForCRack cosmic_seed
 
edm::EDGetTokenT
< SiStripMatchedRecHit2DCollection
matchedrecHitsToken_
 
edm::EDGetTokenT
< SiStripRecHit2DCollection
rphirecHitsToken_
 
edm::EDGetTokenT
< SiStripRecHit2DCollection
stereorecHitsToken_
 

Additional Inherited Members

- Public Types inherited from edm::EDProducer
typedef EDProducer ModuleType
 
- Public Types inherited from edm::ProducerBase
typedef
ProductRegistryHelper::TypeLabelList 
TypeLabelList
 
- Static Public Member Functions inherited from edm::EDProducer
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

Definition at line 14 of file CRackSeedGenerator.h.

Constructor & Destructor Documentation

CRackSeedGenerator::CRackSeedGenerator ( const edm::ParameterSet conf)
explicit

Definition at line 17 of file CRackSeedGenerator.cc.

References conf_, edm::ParameterSet::getParameter(), matchedrecHitsToken_, rphirecHitsToken_, and stereorecHitsToken_.

17  :
18  conf_(conf) ,cosmic_seed(conf)
19  {
20  edm::LogInfo ("CRackSeedGenerator")<<"Enter the CRackSeedGenerator";
21  matchedrecHitsToken_ = consumes<SiStripMatchedRecHit2DCollection>(
22  conf_.getParameter<edm::InputTag>("matchedRecHits"));
23  rphirecHitsToken_ = consumes<SiStripRecHit2DCollection>(
24  conf_.getParameter<edm::InputTag>("rphirecHits"));
25  stereorecHitsToken_ = consumes<SiStripRecHit2DCollection>(
26  conf_.getParameter<edm::InputTag>("stereorecHits"));
27 
28  produces<TrajectorySeedCollection>();
29 }
T getParameter(std::string const &) const
edm::EDGetTokenT< SiStripRecHit2DCollection > rphirecHitsToken_
edm::ParameterSet conf_
SeedGeneratorForCRack cosmic_seed
edm::EDGetTokenT< SiStripMatchedRecHit2DCollection > matchedrecHitsToken_
edm::EDGetTokenT< SiStripRecHit2DCollection > stereorecHitsToken_
CRackSeedGenerator::~CRackSeedGenerator ( )
virtual

Definition at line 33 of file CRackSeedGenerator.cc.

33 { }

Member Function Documentation

void CRackSeedGenerator::produce ( edm::Event e,
const edm::EventSetup c 
)
overridevirtual

Implements edm::EDProducer.

Definition at line 36 of file CRackSeedGenerator.cc.

References cosmic_seed, edm::Event::getByToken(), SeedGeneratorForCRack::init(), LogDebug, matchedrecHitsToken_, convertSQLitetoXML_cfg::output, edm::Event::put(), rphirecHitsToken_, SeedGeneratorForCRack::run(), and stereorecHitsToken_.

37 {
38  // get Inputs
40  ev.getByToken(rphirecHitsToken_, rphirecHits);
42  ev.getByToken(stereorecHitsToken_, stereorecHits);
44  ev.getByToken(matchedrecHitsToken_, matchedrecHits);
45 
46 
47  std::auto_ptr<TrajectorySeedCollection> output(new TrajectorySeedCollection);
48  //
49 
50  cosmic_seed.init(*stereorecHits,*rphirecHits,*matchedrecHits, es);
51 
52  // invoke the seed finding algorithm
53  cosmic_seed.run(*output,es);
54 
55  // write output to file
56  LogDebug("CRackSeedGenerator")<<" number of seeds = "<< output->size();
57 
58 
59  ev.put(output);
60 }
#define LogDebug(id)
bool ev
edm::EDGetTokenT< SiStripRecHit2DCollection > rphirecHitsToken_
std::vector< TrajectorySeed > TrajectorySeedCollection
SeedGeneratorForCRack cosmic_seed
void init(const SiStripRecHit2DCollection &collstereo, const SiStripRecHit2DCollection &collrphi, const SiStripMatchedRecHit2DCollection &collmatched, const edm::EventSetup &c)
edm::EDGetTokenT< SiStripMatchedRecHit2DCollection > matchedrecHitsToken_
void run(TrajectorySeedCollection &, const edm::EventSetup &c)
edm::EDGetTokenT< SiStripRecHit2DCollection > stereorecHitsToken_

Member Data Documentation

edm::ParameterSet CRackSeedGenerator::conf_
private

Definition at line 25 of file CRackSeedGenerator.h.

Referenced by CRackSeedGenerator().

SeedGeneratorForCRack CRackSeedGenerator::cosmic_seed
private

Definition at line 26 of file CRackSeedGenerator.h.

Referenced by produce().

edm::EDGetTokenT<SiStripMatchedRecHit2DCollection> CRackSeedGenerator::matchedrecHitsToken_
private

Definition at line 27 of file CRackSeedGenerator.h.

Referenced by CRackSeedGenerator(), and produce().

edm::EDGetTokenT<SiStripRecHit2DCollection> CRackSeedGenerator::rphirecHitsToken_
private

Definition at line 28 of file CRackSeedGenerator.h.

Referenced by CRackSeedGenerator(), and produce().

edm::EDGetTokenT<SiStripRecHit2DCollection> CRackSeedGenerator::stereorecHitsToken_
private

Definition at line 29 of file CRackSeedGenerator.h.

Referenced by CRackSeedGenerator(), and produce().