30 if (trackTypeName ==
"muonBestTrack")
32 else if (trackTypeName ==
"innerTrack")
35 edm::LogError(
"MuonDzCut") <<
"Wrong cut id name, " << trackTypeName
36 <<
"Choose among \"muonBestTrack\", \"innerTrack\"";
57 const auto& vtxPos =
vtxs_->at(0).position();
61 trackRef = cand->innerTrack();
63 trackRef = cand->muonBestTrack();
72 trackRef = muon->innerTrack();
74 trackRef = muon->muonBestTrack();
78 const auto& vtxPos =
vtxs_->at(0).position();
79 return std::abs(trackRef->dz(vtxPos));
EDGetTokenT< ProductType > consumes(edm::InputTag const &tag)
const edm::EventSetup & c
bool isNonnull() const
Checks for non-null.
std::unordered_map< std::string, edm::InputTag > contentTags_
enum MuonDzCut::BestTrackType trackType_
edm::Handle< reco::VertexCollection > vtxs_
std::vector< Vertex > VertexCollection
collection of Vertex objects
double value(const reco::CandidatePtr &) const final
Log< level::Error, false > LogError
std::vector< Vertex > VertexCollection
MuonDzCut(const edm::ParameterSet &c)
Abs< T >::type abs(const T &t)
bool isNull() const
Checks for null.
void setConsumes(edm::ConsumesCollector &) final
std::unordered_map< std::string, edm::EDGetToken > contentTokens_
T getParameter(std::string const &) const
void getEventContent(const edm::EventBase &) final
bool getByLabel(InputTag const &, Handle< T > &) const
CandidateType candidateType() const final
result_type operator()(const reco::MuonPtr &) const final
#define DEFINE_EDM_PLUGIN(factory, type, name)