57 : max_dxy_ ( iConfig.getParameter<double>(
"max_dxy" ) )
58 , max_dz_ ( iConfig.getParameter<double>(
"max_dz" ) )
59 , v_recoVertexToken_ ( consumes< std::vector<
reco::Vertex> >( iConfig.getParameter<edm::InputTag>(
"srcVertex" ) ) )
60 , v_recoGsfElectronToken_( consumes< std::vector<
reco::GsfElectron> >( iConfig.getParameter<edm::InputTag>(
"srcElectron" ) ) )
62 produces<std::vector<reco::GsfElectron> >();
76 std::auto_ptr<std::vector<reco::GsfElectron> > goodGsfElectrons(
new std::vector<reco::GsfElectron >);
84 if( (VertexHandle->size() == 0) || (GsfElectronHandle->size() == 0) )
86 iEvent.
put(goodGsfElectrons);
92 std::vector<reco::GsfElectron>::const_iterator GsfElectronIt ;
95 for (GsfElectronIt = GsfElectronHandle->begin(); GsfElectronIt != GsfElectronHandle->end(); ++GsfElectronIt) {
101 goodGsfElectrons -> push_back(*GsfElectronIt) ;
105 iEvent.
put(goodGsfElectrons);
bool getByToken(EDGetToken token, Handle< PROD > &result) const
#define DEFINE_FWK_MODULE(type)
const Point & position() const
position
edm::EDGetTokenT< std::vector< reco::GsfElectron > > v_recoGsfElectronToken_
OrphanHandle< PROD > put(std::auto_ptr< PROD > product)
Put a new product.
GsfElectronFromPVSelector(const edm::ParameterSet &iConfig)
void produce(edm::Event &iEvent, const edm::EventSetup &iSetup) override
virtual ~GsfElectronFromPVSelector()
edm::EDGetTokenT< std::vector< reco::Vertex > > v_recoVertexToken_