CMS 3D CMS Logo

NuclearInteractionTrackImporter.cc
Go to the documentation of this file.
3 
4 namespace {
5  class NuclAdaptor {
6  public:
7  static bool check_importable(const reco::PFDisplacedTrackerVertexCollection::value_type& t) {
8  const auto& vtx = t.displacedVertexRef();
9  return ( vtx->isNucl() && vtx->position().rho() > 2.7 );
10  }
11  static const reco::PFRecTrackRefVector&
13  return t.pfRecTracks();
14  }
15  static void set_element_info(reco::PFBlockElement* elem,
17  const reco::PFBlockElementTrack *tkelem =
18  static_cast<const reco::PFBlockElementTrack*>(elem);
19  const reco::PFRecTrackRef& reftrack = tkelem->trackRefPF();
21  if(parref->isIncomingTrack(reftrack))
23  else if (parref->isOutgoingTrack(reftrack))
25  elem->setDisplacedVertexRef(parref,tkType);
26  }
27  };
28 }
29 
31 
33  NuclearInteractionTrackImporter,
34  "NuclearInteractionTrackImporter");
Abstract base class for a PFBlock element (track, cluster...)
pflow::importers::TrackFromParentImporter< reco::PFDisplacedTrackerVertexCollection, NuclAdaptor > NuclearInteractionTrackImporter
virtual void setDisplacedVertexRef(const PFDisplacedTrackerVertexRef &niref, TrackType trType)
def elem(elemtype, innerHTML='', html_class='', kwargs)
Definition: HTMLExport.py:19
const PFRecTrackRef & trackRefPF() const override
#define DEFINE_EDM_PLUGIN(factory, type, name)