CMS 3D CMS Logo

CSCSegmentProducer.cc
Go to the documentation of this file.
1 
7 
12 
15 
17  m_token = consumes<CSCRecHit2DCollection>(pas.getParameter<edm::InputTag>("inputObjects"));
18  m_cscGeometryToken = esConsumes<CSCGeometry, MuonGeometryRecord>();
19  segmentBuilder_ = new CSCSegmentBuilder(pas); // pass on the PS
20 
21  // register what this produces
22  produces<CSCSegmentCollection>();
23 }
24 
26  LogDebug("CSCSegment|CSC") << "deleting CSCSegmentBuilder after " << iev << " events w/csc data.";
27  delete segmentBuilder_;
28 }
29 
31  LogDebug("CSCSegment|CSC") << "start producing segments for " << ++iev << "th event with csc data";
32 
33  // find the geometry (& conditions?) for this event & cache it in the builder
34 
36  const CSCGeometry* pgeom = &*h;
38 
39  // get the collection of CSCRecHit2D
41  ev.getByToken(m_token, cscRecHits);
42 
43  // create empty collection of Segments
44  auto oc = std::make_unique<CSCSegmentCollection>();
45 
46  // fill the collection
47  segmentBuilder_->build(cscRecHits.product(), *oc); //@@ FILL oc
48 
49  // put collection in event
50  ev.put(std::move(oc));
51 }
void produce(edm::Event &, const edm::EventSetup &) override
Produce the CSCSegment collection.
void build(const CSCRecHit2DCollection *rechits, CSCSegmentCollection &oc)
T getParameter(std::string const &) const
Definition: ParameterSet.h:307
T const * product() const
Definition: Handle.h:70
edm::EDGetTokenT< CSCRecHit2DCollection > m_token
CSCSegmentBuilder * segmentBuilder_
edm::ESGetToken< CSCGeometry, MuonGeometryRecord > m_cscGeometryToken
CSCSegmentProducer(const edm::ParameterSet &)
Constructor.
HitContainer const *__restrict__ TkSoA const *__restrict__ Quality const *__restrict__ CAHitNtupletGeneratorKernelsGPU::HitToTuple const *__restrict__ int32_t int32_t int iev
~CSCSegmentProducer() override
Destructor.
The Signals That Services Can Subscribe To This is based on ActivityRegistry h
Helper function to determine trigger accepts.
Definition: Activities.doc:4
void setGeometry(const CSCGeometry *geom)
def move(src, dest)
Definition: eostools.py:511
#define LogDebug(id)