Main Page
Namespaces
Classes
Package Documentation
RecoParticleFlow
PFProducer
plugins
importers
NuclearInteractionTrackImporter.cc
Go to the documentation of this file.
1
#include "
TrackFromParentImporter.h
"
2
#include "
DataFormats/ParticleFlowReco/interface/PFDisplacedTrackerVertex.h
"
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
&
12
get_track_refs(
const
reco::PFDisplacedTrackerVertexCollection::value_type
& t) {
13
return
t.pfRecTracks();
14
}
15
static
void
set_element_info(
reco::PFBlockElement
*
elem
,
16
const
edm::Ref<reco::PFDisplacedTrackerVertexCollection>
& parref) {
17
const
reco::PFBlockElementTrack
*tkelem =
18
static_cast<
const
reco::PFBlockElementTrack
*
>
(
elem
);
19
const
reco::PFRecTrackRef
& reftrack = tkelem->
trackRefPF
();
20
reco::PFBlockElement::TrackType
tkType =
reco::PFBlockElement::DEFAULT
;
21
if
(parref->isIncomingTrack(reftrack))
22
tkType =
reco::PFBlockElement::T_TO_DISP
;
23
else
if
(parref->isOutgoingTrack(reftrack))
24
tkType =
reco::PFBlockElement::T_FROM_DISP
;
25
elem->
setDisplacedVertexRef
(parref,tkType);
26
}
27
};
28
}
29
30
typedef
pflow::importers::TrackFromParentImporter<reco::PFDisplacedTrackerVertexCollection,NuclAdaptor>
NuclearInteractionTrackImporter
;
31
32
DEFINE_EDM_PLUGIN
(
BlockElementImporterFactory
,
33
NuclearInteractionTrackImporter,
34
"NuclearInteractionTrackImporter"
);
reco::PFBlockElement
Abstract base class for a PFBlock element (track, cluster...)
Definition:
PFBlockElement.h:28
extraflags_cff.vtx
vtx
Definition:
extraflags_cff.py:18
pflow::importers::TrackFromParentImporter
Definition:
TrackFromParentImporter.h:31
edm::Ref
Definition:
AssociativeIterator.h:51
reco::PFBlockElement::TrackType
TrackType
Definition:
PFBlockElement.h:50
NuclearInteractionTrackImporter
pflow::importers::TrackFromParentImporter< reco::PFDisplacedTrackerVertexCollection, NuclAdaptor > NuclearInteractionTrackImporter
Definition:
NuclearInteractionTrackImporter.cc:30
TrackFromParentImporter.h
reco::JetExtendedAssociation::value_type
Container::value_type value_type
Definition:
JetExtendedAssociation.h:30
PFDisplacedTrackerVertex.h
edmplugin::PluginFactory
Definition:
PluginFactory.h:33
reco::PFBlockElement::T_TO_DISP
Definition:
PFBlockElement.h:53
reco::PFBlockElement::setDisplacedVertexRef
virtual void setDisplacedVertexRef(const PFDisplacedTrackerVertexRef &niref, TrackType trType)
Definition:
PFBlockElement.h:111
HTMLExport.elem
def elem(elemtype, innerHTML='', html_class='', kwargs)
Definition:
HTMLExport.py:19
edm::RefVector< PFRecTrackCollection >
reco::PFBlockElementTrack::trackRefPF
const PFRecTrackRef & trackRefPF() const override
Definition:
PFBlockElementTrack.h:54
reco::PFBlockElement::T_FROM_DISP
Definition:
PFBlockElement.h:52
lumiQTWidget.t
t
Definition:
lumiQTWidget.py:50
DEFINE_EDM_PLUGIN
#define DEFINE_EDM_PLUGIN(factory, type, name)
Definition:
PluginFactory.h:121
reco::PFBlockElement::DEFAULT
Definition:
PFBlockElement.h:51
reco::PFBlockElementTrack
Track Element.
Definition:
PFBlockElementTrack.h:17
Generated for CMSSW Reference Manual by
1.8.11