CMS 3D CMS Logo

Functions
TrackSorting Namespace Reference

Functions

reco::btag::SortCriteria getCriterium (const std::string &name)
 

Function Documentation

◆ getCriterium()

reco::btag::SortCriteria TrackSorting::getCriterium ( const std::string &  name)

Definition at line 11 of file TrackSorting.cc.

References Exception, reco::btag::IP2DSig, reco::btag::IP2DValue, reco::btag::IP3DSig, mergeVDriftHistosByStation::name, reco::btag::Prob2D, and reco::btag::Prob3D.

11  {
12  using namespace reco::btag;
13  if (name == "sip3dSig")
14  return IP3DSig;
15  if (name == "prob3d")
16  return Prob3D;
17  if (name == "sip2dSig")
18  return IP2DSig;
19  if (name == "prob2d")
20  return Prob2D;
21  if (name == "sip2dVal")
22  return IP2DValue;
23 
24  throw cms::Exception("InvalidArgument") << "Identifier \"" << name << "\" does not represent a valid "
25  << "track sorting criterium." << std::endl;
26 }