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

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

Definition at line 61 of file IPProducer.h.

EDGetTokenT< ProductType > consumes(edm::InputTag const &tag)
T getParameter(std::string const &) const
edm::EDGetTokenT< reco::JetTracksAssociationCollection > token_associator
Definition: IPProducer.h:79

Member Function Documentation

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

Definition at line 65 of file IPProducer.h.

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

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  }
transient_vector_type::const_iterator const_iterator
bool getByToken(EDGetToken token, Handle< PROD > &result) const
Definition: Event.h:525
const_iterator end() const
edm::EDGetTokenT< reco::JetTracksAssociationCollection > token_associator
Definition: IPProducer.h:79
const_iterator begin() const
reco::TrackRefVector IPProducerHelpers::FromJTA::tracks ( const reco::JTATagInfo it)
inline

Definition at line 64 of file IPProducer.h.

References reco::JTATagInfo::tracks().

64 { return it.tracks(); }
TrackRefVector tracks(void) const override
returns a list of tracks associated to the jet
Definition: JTATagInfo.h:20

Member Data Documentation

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

Definition at line 79 of file IPProducer.h.

Referenced by makeBaseVector().