CMS 3D CMS Logo

List of all members | Public Types | Public Member Functions
ticl::TracksterRecoTrackPlugin Class Referencefinal
Inheritance diagram for ticl::TracksterRecoTrackPlugin:
ticl::TracksterTrackPluginBase

Public Types

typedef edm::Ptr< reco::TrackTrackPtr
 
- Public Types inherited from ticl::TracksterTrackPluginBase
typedef reco::Candidate::LorentzVector LorentzVector
 

Public Member Functions

void setTrack (const std::vector< const Trackster * > &tracksters, std::vector< TICLCandidate > &ticl_cands, edm::Event &event) const override
 
 TracksterRecoTrackPlugin (const edm::ParameterSet &, edm::ConsumesCollector &&iC)
 
- Public Member Functions inherited from ticl::TracksterTrackPluginBase
 TracksterTrackPluginBase (const edm::ParameterSet &, edm::ConsumesCollector &&iC)
 
virtual ~TracksterTrackPluginBase ()
 

Detailed Description

Definition at line 10 of file TracksterGeneralTrackPlugin.cc.

Member Typedef Documentation

Definition at line 12 of file TracksterGeneralTrackPlugin.cc.

Constructor & Destructor Documentation

ticl::TracksterRecoTrackPlugin::TracksterRecoTrackPlugin ( const edm::ParameterSet ps,
edm::ConsumesCollector &&  iC 
)
explicit

Definition at line 19 of file TracksterGeneralTrackPlugin.cc.

TracksterTrackPluginBase(const edm::ParameterSet &, edm::ConsumesCollector &&iC)
def move(src, dest)
Definition: eostools.py:511

Member Function Documentation

void ticl::TracksterRecoTrackPlugin::setTrack ( const std::vector< const Trackster * > &  tracksters,
std::vector< TICLCandidate > &  ticl_cands,
edm::Event event 
) const
overridevirtual

Implements ticl::TracksterTrackPluginBase.

Definition at line 22 of file TracksterGeneralTrackPlugin.cc.

References DEFINE_EDM_PLUGIN, mps_fire::i, min(), edm::Event::productGetter(), and findQualityFiles::size.

24  {
25  auto size = std::min(tracksters.size(), ticl_cands.size());
26  for (size_t i = 0; i < size; ++i) {
27  const auto& trackster = *tracksters[i];
28 
29  if (trackster.seedIndex == 0 || !trackster.seedID.isValid()) {
30  return; // leave default empty track ref
31  }
32 
33  TrackPtr ptr(trackster.seedID, trackster.seedIndex, &event.productGetter());
34  auto& ticl_cand = ticl_cands[i];
35  ticl_cand.setTrackPtr(ptr);
36  }
37  }
size
Write out results.
EDProductGetter const & productGetter() const
Definition: Event.cc:102
T min(T a, T b)
Definition: MathUtil.h:58