CMS 3D CMS Logo

CombinedHitQuadrupletGeneratorForPhotonConversion.cc
Go to the documentation of this file.
6 
9  : theSeedingLayerToken(iC.consumes<SeedingLayerSetsHits>(cfg.getParameter<edm::InputTag>("SeedingLayers"))),
10  theMaxElement(cfg.getParameter<unsigned int>("maxElement")) {
11  theGenerator =
12  std::make_unique<HitQuadrupletGeneratorFromLayerPairForPhotonConversion>(0, 1, &theLayerCache, theMaxElement);
13 }
14 
16 
18  const edm::Event& ev,
19  const edm::EventSetup& es) {
20  thePairs.clear();
21  hitPairs(region, thePairs, ev, es);
22  return thePairs;
23 }
24 
27  const edm::Event& ev,
28  const edm::EventSetup& es) {
29  size_t maxHitQuadruplets = 1000000;
31  ev.getByToken(theSeedingLayerToken, hlayers);
32  const SeedingLayerSetsHits& layers = *hlayers;
33  assert(layers.numberOfLayersInSet() == 2);
34 
35  for (SeedingLayerSetsHits::LayerSetIndex i = 0; i < hlayers->size() && result.size() < maxHitQuadruplets; ++i) {
36  theGenerator->hitPairs(region, result, layers[i]);
37  }
39 }
unsigned short LayerSetIndex
unsigned short size() const
Get the number of SeedingLayerSets.
assert(be >=bs)
void hitPairs(const TrackingRegion &, OrderedHitPairs &, const edm::Event &, const edm::EventSetup &)
const OrderedHitPairs & run(const TrackingRegion &region, const edm::Event &ev, const edm::EventSetup &es)
std::unique_ptr< HitQuadrupletGeneratorFromLayerPairForPhotonConversion > theGenerator
HLT enums.
CombinedHitQuadrupletGeneratorForPhotonConversion(const edm::ParameterSet &cfg, edm::ConsumesCollector &iC)