CMS 3D CMS Logo

List of all members | Public Member Functions | Public Attributes
IPProducerHelpers::FromJTA Class Reference

#include <IPProducer.h>

Public Member Functions

 FromJTA (const edm::ParameterSet &iConfig, edm::ConsumesCollector &&iC)
 
std::vector< reco::JTATagInfomakeBaseVector (const edm::Event &iEvent)
 
reco::TrackRefVector tracks (const reco::JTATagInfo &it)
 

Public Attributes

edm::EDGetTokenT< reco::JetTracksAssociationCollectiontoken_associator
 

Detailed Description

Definition at line 59 of file IPProducer.h.

Constructor & Destructor Documentation

◆ FromJTA()

IPProducerHelpers::FromJTA::FromJTA ( const edm::ParameterSet iConfig,
edm::ConsumesCollector &&  iC 
)
inline

Definition at line 61 of file IPProducer.h.

Member Function Documentation

◆ makeBaseVector()

std::vector<reco::JTATagInfo> IPProducerHelpers::FromJTA::makeBaseVector ( const edm::Event iEvent)
inline

Definition at line 65 of file IPProducer.h.

65  {
67  iEvent.getByToken(token_associator, jetTracksAssociation);
68  std::vector<reco::JTATagInfo> bases;
69  size_t i = 0;
70  for (reco::JetTracksAssociationCollection::const_iterator it = jetTracksAssociation->begin();
71  it != jetTracksAssociation->end();
72  it++, i++) {
73  edm::Ref<reco::JetTracksAssociationCollection> jtaRef(jetTracksAssociation, i);
74  bases.push_back(reco::JTATagInfo(jtaRef));
75  }
76  return bases;
77  }

References edm::AssociationVector< KeyRefProd, CVal, KeyRef, SizeType, KeyReferenceHelper >::begin(), edm::AssociationVector< KeyRefProd, CVal, KeyRef, SizeType, KeyReferenceHelper >::end(), mps_fire::i, iEvent, and token_associator.

◆ tracks()

reco::TrackRefVector IPProducerHelpers::FromJTA::tracks ( const reco::JTATagInfo it)
inline

Definition at line 64 of file IPProducer.h.

64 { return it.tracks(); }

References reco::JTATagInfo::tracks().

Member Data Documentation

◆ token_associator

edm::EDGetTokenT<reco::JetTracksAssociationCollection> IPProducerHelpers::FromJTA::token_associator

Definition at line 79 of file IPProducer.h.

Referenced by makeBaseVector().

reco::JTATagInfo::tracks
TrackRefVector tracks(void) const override
returns a list of tracks associated to the jet
Definition: JTATagInfo.h:20
mps_fire.i
i
Definition: mps_fire.py:355
edm::Handle
Definition: AssociativeIterator.h:50
edm::Ref
Definition: AssociativeIterator.h:58
edm::AssociationVector::begin
const_iterator begin() const
Definition: AssociationVector.h:108
IPProducerHelpers::FromJTA::token_associator
edm::EDGetTokenT< reco::JetTracksAssociationCollection > token_associator
Definition: IPProducer.h:79
edm::ConsumesCollector::consumes
EDGetTokenT< ProductType > consumes(edm::InputTag const &tag)
Definition: ConsumesCollector.h:49
edm::AssociationVector::end
const_iterator end() const
Definition: AssociationVector.h:109
edm::AssociationVector
Definition: AssociationVector.h:67
iEvent
int iEvent
Definition: GenABIO.cc:224
edm::AssociationVector::const_iterator
transient_vector_type::const_iterator const_iterator
Definition: AssociationVector.h:106
edm::ParameterSet::getParameter
T getParameter(std::string const &) const
reco::JTATagInfo
Definition: JTATagInfo.h:10
edm::InputTag
Definition: InputTag.h:15