Produces a list containing a single vertex selected by some criteria. More...
#include "PhysicsTools/PatAlgos/plugins/PATSingleVertexSelector.h"
Private Types | |
typedef StringCutObjectSelector < reco::Candidate > | CandSel |
enum | Mode { First, NearestToCand, FromCand, FromBeamSpot } |
typedef StringCutObjectSelector < reco::Vertex > | VtxSel |
Private Member Functions | |
std::auto_ptr< std::vector < reco::Vertex > > | filter_ (Mode mode, const edm::Event &iEvent, const edm::EventSetup &iSetup) |
bool | hasMode_ (Mode mode) const |
Static Private Member Functions | |
static Mode | parseMode (const std::string &name) |
Private Attributes | |
edm::EDGetTokenT< reco::BeamSpot > | beamSpotToken_ |
const reco::Candidate * | bestCand_ |
std::vector< edm::EDGetTokenT < edm::View< reco::Candidate > > > | candidatesToken_ |
std::auto_ptr< CandSel > | candPreselection_ |
bool | doFilterEvents_ |
std::vector< Mode > | modes_ |
std::vector< const reco::Vertex * > | selVtxs_ |
edm::EDGetTokenT< std::vector < reco::Vertex > > | verticesToken_ |
std::auto_ptr< VtxSel > | vtxPreselection_ |
Additional Inherited Members | |
Public Types inherited from edm::EDFilter | |
typedef EDFilter | ModuleType |
Public Types inherited from edm::ProducerBase | |
typedef ProductRegistryHelper::TypeLabelList | TypeLabelList |
Static Public Member Functions inherited from edm::EDFilter | |
static const std::string & | baseType () |
static void | fillDescriptions (ConfigurationDescriptions &descriptions) |
static void | prevalidate (ConfigurationDescriptions &) |
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) |
Produces a list containing a single vertex selected by some criteria.
Definition at line 26 of file PATSingleVertexSelector.h.
|
private |
Definition at line 38 of file PATSingleVertexSelector.h.
|
private |
Definition at line 37 of file PATSingleVertexSelector.h.
|
private |
Enumerator | |
---|---|
First | |
NearestToCand | |
FromCand | |
FromBeamSpot |
Definition at line 36 of file PATSingleVertexSelector.h.
|
explicit |
Definition at line 29 of file PATSingleVertexSelector.cc.
References candidatesToken_, candPreselection_, edm::EDConsumerBase::consumes(), edm::ParameterSet::exists(), edm::ParameterSet::existsAs(), First, FromCand, edm::ParameterSet::getParameter(), hasMode_(), modes_, NearestToCand, parseMode(), AlCaHLTBitMon_QueryRunRegistry::string, GlobalPosition_Frontier_DevDB_cff::tag, edm::vector_transform(), verticesToken_, and vtxPreselection_.
PATSingleVertexSelector::~PATSingleVertexSelector | ( | ) |
Definition at line 65 of file PATSingleVertexSelector.cc.
|
overridevirtual |
Implements edm::EDFilter.
Definition at line 74 of file PATSingleVertexSelector.cc.
References bestCand_, candidatesToken_, candPreselection_, doFilterEvents_, filter_(), First, FromCand, edm::Event::getByToken(), hasMode_(), modes_, NearestToCand, edm::Event::put(), query::result, selVtxs_, verticesToken_, and vtxPreselection_.
|
private |
Definition at line 124 of file PATSingleVertexSelector.cc.
References funct::abs(), SiPixelRawToDigiRegional_cfi::beamSpot, beamSpotToken_, bestCand_, First, FromBeamSpot, FromCand, edm::Event::getByToken(), NearestToCand, reco::Candidate::numberOfDaughters(), query::result, selVtxs_, hltvertexperformanceanalyzer_cfi::Vertex, reco::Candidate::vertex(), reco::Candidate::vertexChi2(), reco::Candidate::vertexCovariance(), reco::Candidate::vertexNdof(), and reco::Candidate::vz().
Referenced by filter().
|
private |
Definition at line 69 of file PATSingleVertexSelector.cc.
References spr::find(), alignBH_cfg::mode, and modes_.
Referenced by filter(), and PATSingleVertexSelector().
|
staticprivate |
Definition at line 14 of file PATSingleVertexSelector.cc.
References edm::hlt::Exception, First, FromBeamSpot, FromCand, and NearestToCand.
Referenced by PATSingleVertexSelector().
|
private |
Definition at line 50 of file PATSingleVertexSelector.h.
Referenced by filter_().
|
private |
Definition at line 53 of file PATSingleVertexSelector.h.
|
private |
Definition at line 47 of file PATSingleVertexSelector.h.
Referenced by filter(), and PATSingleVertexSelector().
|
private |
Definition at line 49 of file PATSingleVertexSelector.h.
Referenced by filter(), and PATSingleVertexSelector().
|
private |
Definition at line 58 of file PATSingleVertexSelector.h.
Referenced by filter().
|
private |
Definition at line 45 of file PATSingleVertexSelector.h.
Referenced by filter(), hasMode_(), and PATSingleVertexSelector().
|
private |
Definition at line 52 of file PATSingleVertexSelector.h.
|
private |
Definition at line 46 of file PATSingleVertexSelector.h.
Referenced by filter(), and PATSingleVertexSelector().
|
private |
Definition at line 48 of file PATSingleVertexSelector.h.
Referenced by filter(), and PATSingleVertexSelector().