Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2024-04-06 12:26:14

0001 #ifndef GEMRecHit_ME0SegmentBuilder_h
0002 #define GEMRecHit_ME0SegmentBuilder_h
0003 
0004 /** \class ME0SegmentBuilder derived by CSCSegmentBuilder
0005  * Algorithm to build ME0Segment's from ME0RecHit collection
0006  * by implementing a 'build' function required by ME0SegmentProducer.
0007  *
0008  * Implementation notes: <BR>
0009  * Configured via the Producer's ParameterSet. <BR>
0010  * Presume this might become an abstract base class one day. <BR>
0011  *
0012  * $Date: 2014/02/04 13:45:31 $
0013  * $Revision: 1.1 $
0014  * \author Marcello Maggi
0015  *
0016  */
0017 
0018 #include "DataFormats/GEMRecHit/interface/ME0RecHitCollection.h"
0019 #include "DataFormats/GEMRecHit/interface/ME0SegmentCollection.h"
0020 #include "Geometry/GEMGeometry/interface/ME0Geometry.h"
0021 #include "FWCore/ParameterSet/interface/ParameterSet.h"
0022 
0023 class ME0SegmentAlgorithmBase;
0024 
0025 class ME0SegmentBuilder {
0026 public:
0027   /** Configure the algorithm via ctor.
0028    * Receives ParameterSet percolated down from EDProducer
0029    * which owns this Builder.
0030    */
0031   explicit ME0SegmentBuilder(const edm::ParameterSet&);
0032   /// Destructor
0033   ~ME0SegmentBuilder();
0034 
0035   /** Find rechits in each ensemble of all ME0 layers, build ME0Segment's ,
0036    *  and fill into output collection.
0037    */
0038   void build(const ME0RecHitCollection* rechits, ME0SegmentCollection& oc);
0039 
0040   /** Cache pointer to geometry _for current event_
0041    */
0042   void setGeometry(const ME0Geometry* g);
0043 
0044 private:
0045   std::unique_ptr<ME0SegmentAlgorithmBase> algo;
0046   const ME0Geometry* geom_;
0047 };
0048 
0049 #endif