#include <AssociationMap.h>
Classes | |
struct | const_iterator |
const iterator More... | |
struct | Find |
find helper More... | |
Public Types | |
typedef Tag::data_type | data_type |
insert data type | |
typedef Tag::index_type | index_type |
index type | |
typedef std::map< index_type, value_type > | internal_transient_map_type |
transient map type | |
typedef Tag::key_type | key_type |
insert key type | |
typedef Tag::map_type | map_type |
map type | |
typedef Tag::ref_type | ref_type |
reference set type | |
typedef value_type::value_type | result_type |
result type | |
typedef AssociationMap< Tag > | self |
self type | |
typedef map_type::size_type | size_type |
size type | |
typedef helpers::KeyVal < key_type, internal_val_type > | value_type |
value type | |
Public Member Functions | |
AssociationMap () | |
default constructor | |
AssociationMap (const ref_type &ref) | |
default constructor | |
const_iterator | begin () const |
first iterator over the map (read only) | |
void | clear () |
clear map | |
bool | empty () const |
return true if empty | |
const_iterator | end () const |
last iterator over the map (read only) | |
size_type | erase (const key_type &k) |
erase the element whose key is k | |
const_iterator | find (const key_type &k) const |
find element with specified reference key | |
void | insert (const key_type &k, const data_type &v) |
insert an association | |
void | insert (const value_type &kv) |
Tag::transient_key_vector | keys () |
Tag::transient_map_type | map () |
size_type | numberOfAssociations (const key_type &k) const |
number of associations to a key | |
const result_type & | operator[] (const key_type &k) const |
find element with specified reference key | |
void | post_insert () |
post insert action | |
const ref_type & | refProd () const |
return ref-prod structure | |
size_type | size () const |
map size | |
Tag::transient_val_vector | values () |
Private Types | |
typedef Tag::val_type | internal_val_type |
insert key type | |
Private Member Functions | |
const_iterator | find (size_type i) const |
find element with index i | |
const value_type & | operator[] (size_type i) const |
return value_typeelement with key i | |
Private Attributes | |
map_type | map_ |
index map | |
ref_type | ref_ |
reference set | |
internal_transient_map_type | transientMap_ |
transient reference map | |
Friends | |
struct | const_iterator |
struct | Find |
class | OneToMany |
class | OneToManyWithQuality |
class | OneToOne |
class | OneToValue |
struct | refhelper::FindTrait< self, value_type > |
one-to-many or one-to-one associative map using EDM references
Definition at line 20 of file AssociationMap.h.
typedef Tag::data_type edm::AssociationMap< Tag >::data_type |
insert data type
Definition at line 31 of file AssociationMap.h.
typedef Tag::index_type edm::AssociationMap< Tag >::index_type |
index type
Definition at line 27 of file AssociationMap.h.
typedef std::map<index_type, value_type> edm::AssociationMap< Tag >::internal_transient_map_type |
transient map type
Definition at line 43 of file AssociationMap.h.
typedef Tag::val_type edm::AssociationMap< Tag >::internal_val_type [private] |
insert key type
Definition at line 22 of file AssociationMap.h.
typedef Tag::key_type edm::AssociationMap< Tag >::key_type |
insert key type
Definition at line 29 of file AssociationMap.h.
typedef Tag::map_type edm::AssociationMap< Tag >::map_type |
map type
Definition at line 35 of file AssociationMap.h.
typedef Tag::ref_type edm::AssociationMap< Tag >::ref_type |
reference set type
Definition at line 33 of file AssociationMap.h.
typedef value_type::value_type edm::AssociationMap< Tag >::result_type |
result type
Definition at line 41 of file AssociationMap.h.
typedef AssociationMap<Tag> edm::AssociationMap< Tag >::self |
self type
Definition at line 25 of file AssociationMap.h.
typedef map_type::size_type edm::AssociationMap< Tag >::size_type |
size type
Definition at line 37 of file AssociationMap.h.
typedef helpers::KeyVal<key_type, internal_val_type> edm::AssociationMap< Tag >::value_type |
value type
Definition at line 39 of file AssociationMap.h.
edm::AssociationMap< Tag >::AssociationMap | ( | ) | [inline] |
edm::AssociationMap< Tag >::AssociationMap | ( | const ref_type & | ref | ) | [inline, explicit] |
const_iterator edm::AssociationMap< Tag >::begin | ( | void | ) | const [inline] |
first iterator over the map (read only)
Definition at line 90 of file AssociationMap.h.
Referenced by DeDxDiscriminatorLearner::algoAnalyze(), SiStripGainFromData::algoAnalyze(), reco::JetTrackMatch< JetC >::allJets(), SiPixelHitEfficiencySource::analyze(), SiPixelTrackResidualSource::analyze(), DeDxEstimatorProducer::produce(), ShallowSimTracksProducer::produce(), and DeDxDiscriminatorProducer::produce().
{ return const_iterator(this, map_.begin()); }
void edm::AssociationMap< Tag >::clear | ( | void | ) | [inline] |
bool edm::AssociationMap< Tag >::empty | ( | ) | const [inline] |
const_iterator edm::AssociationMap< Tag >::end | ( | void | ) | const [inline] |
last iterator over the map (read only)
Definition at line 92 of file AssociationMap.h.
Referenced by DeDxDiscriminatorLearner::algoAnalyze(), SiStripGainFromData::algoAnalyze(), reco::JetTrackMatch< JetC >::allJets(), ValidationMisalignedTracker::analyze(), PhotonValidator::analyze(), SiPixelHitEfficiencySource::analyze(), SiPixelTrackResidualSource::analyze(), MultiTrackValidator::analyze(), MuonTrackValidator::analyze(), TestTrackHits::analyze(), RecoMuonValidator::analyze(), TkConvValidator::analyze(), edm::AssociationMap< edm::OneToManyWithQualityGeneric< TrackingParticleCollection, edm::View< reco::Track >, double > >::find(), HLTEgammaCaloIsolFilterPairs::PassCaloIsolation(), DeDxEstimatorProducer::produce(), MCTrackMatcher::produce(), NuclearInteractionEDProducer::produce(), ShallowSimTracksProducer::produce(), DeDxDiscriminatorProducer::produce(), TrackAlgoCompareUtil::produce(), muon::tevOptimized(), muon::tevOptimizedOld(), and tevOptimizedTMR().
{ return const_iterator(this, map_.end()); }
size_type edm::AssociationMap< Tag >::erase | ( | const key_type & | k | ) | [inline] |
erase the element whose key is k
Definition at line 99 of file AssociationMap.h.
{ index_type i = k.key(); transientMap_.erase(i); return map_.erase(i); }
const_iterator edm::AssociationMap< Tag >::find | ( | const key_type & | k | ) | const [inline] |
find element with specified reference key
Definition at line 94 of file AssociationMap.h.
Referenced by PhotonValidator::analyze(), ValidationMisalignedTracker::analyze(), MultiTrackValidator::analyze(), MuonTrackValidator::analyze(), TestTrackHits::analyze(), RecoMuonValidator::analyze(), TkConvValidator::analyze(), pat::ElectronSelector::electronID_(), edm::AssociationMap< edm::OneToManyWithQualityGeneric< TrackingParticleCollection, edm::View< reco::Track >, double > >::find(), HLTEgammaCaloIsolFilterPairs::PassCaloIsolation(), MCTrackMatcher::produce(), NuclearInteractionEDProducer::produce(), HFRecoEcalCandidateAlgo::produce(), TrackAlgoCompareUtil::produce(), muon::tevOptimized(), muon::tevOptimizedOld(), and tevOptimizedTMR().
const_iterator edm::AssociationMap< Tag >::find | ( | size_type | i | ) | const [inline, private] |
find element with index i
Definition at line 157 of file AssociationMap.h.
void edm::AssociationMap< Tag >::insert | ( | const key_type & | k, |
const data_type & | v | ||
) | [inline] |
insert an association
Definition at line 83 of file AssociationMap.h.
Referenced by PhotonValidator::analyze(), TrackAssociatorByHits::associateRecoToSim(), MuonAssociatorByHits::associateRecoToSim(), TrackAssociatorByChi2::associateRecoToSim(), VertexAssociatorByTracks::associateRecoToSim(), TrackAssociatorByPosition::associateRecoToSim(), MuonAssociatorByHits::associateSimToReco(), VertexAssociatorByTracks::associateSimToReco(), TrackAssociatorByPosition::associateSimToReco(), TrackAssociatorByChi2::associateSimToReco(), TrackAssociatorByHits::associateSimToReco(), reco::JetTrackMatch< JetC >::insert(), edm::AssociationMap< edm::OneToManyWithQualityGeneric< TrackingParticleCollection, edm::View< reco::Track >, double > >::insert(), CosmicMuonLinksProducer::mapTracks(), NuclearTrackCorrector::produce(), EgammaHLTElectronTrackIsolationProducers::produce(), EgammaHLTHcalIsolationDoubleConeProducers::produce(), EgammaHLTCombinedIsolationProducer::produce(), EgammaHLTHcalIsolationProducersRegional::produce(), EgammaHLTElectronDetaDphiProducer::produce(), EgammaHLTPhotonTrackIsolationProducersRegional::produce(), EgammaHLTEcalIsolationProducersRegional::produce(), EgammaHLTR9IDProducer::produce(), EgammaHLTEcalRecIsolationProducer::produce(), EgammaHLTClusterShapeProducer::produce(), and EgammaHLTR9Producer::produce().
{ Tag::insert(ref_, map_, k, v); }
void edm::AssociationMap< Tag >::insert | ( | const value_type & | kv | ) | [inline] |
Definition at line 86 of file AssociationMap.h.
{ Tag::insert(ref_, map_, kv.key, kv.val); }
Tag::transient_key_vector edm::AssociationMap< Tag >::keys | ( | ) | [inline] |
fill and return a transient key vector required for ROOT interactive usage
Definition at line 126 of file AssociationMap.h.
Tag::transient_map_type edm::AssociationMap< Tag >::map | ( | ) | [inline] |
fill and return a transient map required for ROOT interactive usage
Definition at line 121 of file AssociationMap.h.
size_type edm::AssociationMap< Tag >::numberOfAssociations | ( | const key_type & | k | ) | const [inline] |
number of associations to a key
Definition at line 110 of file AssociationMap.h.
Referenced by VertexAssociatorByTracks::associateRecoToSim(), and VertexAssociatorByTracks::associateSimToReco().
const value_type& edm::AssociationMap< Tag >::operator[] | ( | size_type | i | ) | const [inline, private] |
return value_typeelement with key i
Definition at line 163 of file AssociationMap.h.
{ typename internal_transient_map_type::const_iterator tf = transientMap_.find(i); if (tf == transientMap_.end()) { typename map_type::const_iterator f = map_.find(i); if (f == map_.end()) Exception::throwThis(edm::errors::InvalidReference, "can't find reference in AssociationMap at position ", i); value_type v(key_type(ref_.key, i), Tag::val(ref_, f->second)); std::pair<typename internal_transient_map_type::const_iterator, bool> ins = transientMap_.insert(std::make_pair(i, v)); return ins.first->second; } else { return tf->second; } }
const result_type& edm::AssociationMap< Tag >::operator[] | ( | const key_type & | k | ) | const [inline] |
find element with specified reference key
Definition at line 105 of file AssociationMap.h.
Referenced by edm::AssociationMap< edm::OneToManyWithQualityGeneric< TrackingParticleCollection, edm::View< reco::Track >, double > >::operator[]().
{ helpers::checkRef(ref_.key, k); return operator[](k.key()).val; }
void edm::AssociationMap< Tag >::post_insert | ( | ) | [inline] |
post insert action
Definition at line 135 of file AssociationMap.h.
Referenced by MuonTrackValidator::analyze(), TrackAssociatorByHits::associateRecoToSim(), MuonAssociatorByHits::associateRecoToSim(), TrackAssociatorByChi2::associateRecoToSim(), TrackAssociatorByPosition::associateRecoToSim(), MuonAssociatorByHits::associateSimToReco(), TrackAssociatorByPosition::associateSimToReco(), TrackAssociatorByChi2::associateSimToReco(), and TrackAssociatorByHits::associateSimToReco().
const ref_type& edm::AssociationMap< Tag >::refProd | ( | ) | const [inline] |
size_type edm::AssociationMap< Tag >::size | ( | void | ) | const [inline] |
map size
Definition at line 79 of file AssociationMap.h.
Referenced by SiPixelHitEfficiencySource::analyze(), SiPixelTrackResidualSource::analyze(), TrackAssociatorByHits::associateRecoToSim(), VertexAssociatorByTracks::associateRecoToSim(), VertexAssociatorByTracks::associateSimToReco(), TrackAssociatorByHits::associateSimToReco(), edm::AssociationMap< edm::OneToManyWithQualityGeneric< TrackingParticleCollection, edm::View< reco::Track >, double > >::numberOfAssociations(), DeDxEstimatorProducer::produce(), CosmicMuonLinksProducer::produce(), and DeDxDiscriminatorProducer::produce().
{ return map_.size(); }
Tag::transient_val_vector edm::AssociationMap< Tag >::values | ( | ) | [inline] |
fill and return a transient key vector required for ROOT interactive usage
Definition at line 131 of file AssociationMap.h.
friend struct const_iterator [friend] |
Definition at line 177 of file AssociationMap.h.
Referenced by edm::AssociationMap< edm::OneToManyWithQualityGeneric< TrackingParticleCollection, edm::View< reco::Track >, double > >::begin(), edm::AssociationMap< edm::OneToManyWithQualityGeneric< TrackingParticleCollection, edm::View< reco::Track >, double > >::end(), and edm::AssociationMap< edm::OneToManyWithQualityGeneric< TrackingParticleCollection, edm::View< reco::Track >, double > >::find().
friend struct Find [friend] |
Definition at line 178 of file AssociationMap.h.
friend class OneToMany [friend] |
Definition at line 182 of file AssociationMap.h.
friend class OneToManyWithQuality [friend] |
Definition at line 183 of file AssociationMap.h.
friend class OneToOne [friend] |
Definition at line 181 of file AssociationMap.h.
friend class OneToValue [friend] |
Definition at line 180 of file AssociationMap.h.
friend struct refhelper::FindTrait< self, value_type > [friend] |
Definition at line 179 of file AssociationMap.h.
map_type edm::AssociationMap< Tag >::map_ [private] |
index map
Definition at line 153 of file AssociationMap.h.
Referenced by edm::AssociationMap< edm::OneToManyWithQualityGeneric< TrackingParticleCollection, edm::View< reco::Track >, double > >::begin(), edm::AssociationMap< edm::OneToManyWithQualityGeneric< TrackingParticleCollection, edm::View< reco::Track >, double > >::clear(), edm::AssociationMap< edm::OneToManyWithQualityGeneric< TrackingParticleCollection, edm::View< reco::Track >, double > >::empty(), edm::AssociationMap< edm::OneToManyWithQualityGeneric< TrackingParticleCollection, edm::View< reco::Track >, double > >::end(), edm::AssociationMap< edm::OneToManyWithQualityGeneric< TrackingParticleCollection, edm::View< reco::Track >, double > >::erase(), edm::AssociationMap< edm::OneToManyWithQualityGeneric< TrackingParticleCollection, edm::View< reco::Track >, double > >::find(), edm::AssociationMap< edm::OneToManyWithQualityGeneric< TrackingParticleCollection, edm::View< reco::Track >, double > >::insert(), edm::AssociationMap< edm::OneToManyWithQualityGeneric< TrackingParticleCollection, edm::View< reco::Track >, double > >::keys(), edm::AssociationMap< edm::OneToManyWithQualityGeneric< TrackingParticleCollection, edm::View< reco::Track >, double > >::map(), edm::AssociationMap< edm::OneToManyWithQualityGeneric< TrackingParticleCollection, edm::View< reco::Track >, double > >::numberOfAssociations(), edm::AssociationMap< edm::OneToManyWithQualityGeneric< TrackingParticleCollection, edm::View< reco::Track >, double > >::operator[](), edm::AssociationMap< edm::OneToManyWithQualityGeneric< TrackingParticleCollection, edm::View< reco::Track >, double > >::post_insert(), edm::AssociationMap< edm::OneToManyWithQualityGeneric< TrackingParticleCollection, edm::View< reco::Track >, double > >::size(), and edm::AssociationMap< edm::OneToManyWithQualityGeneric< TrackingParticleCollection, edm::View< reco::Track >, double > >::values().
ref_type edm::AssociationMap< Tag >::ref_ [private] |
reference set
Definition at line 151 of file AssociationMap.h.
Referenced by edm::AssociationMap< edm::OneToManyWithQualityGeneric< TrackingParticleCollection, edm::View< reco::Track >, double > >::find(), edm::AssociationMap< edm::OneToManyWithQualityGeneric< TrackingParticleCollection, edm::View< reco::Track >, double > >::insert(), edm::AssociationMap< edm::OneToManyWithQualityGeneric< TrackingParticleCollection, edm::View< reco::Track >, double > >::keys(), edm::AssociationMap< edm::OneToManyWithQualityGeneric< TrackingParticleCollection, edm::View< reco::Track >, double > >::map(), edm::AssociationMap< edm::OneToManyWithQualityGeneric< TrackingParticleCollection, edm::View< reco::Track >, double > >::numberOfAssociations(), edm::AssociationMap< edm::OneToManyWithQualityGeneric< TrackingParticleCollection, edm::View< reco::Track >, double > >::operator[](), edm::AssociationMap< edm::OneToManyWithQualityGeneric< TrackingParticleCollection, edm::View< reco::Track >, double > >::refProd(), and edm::AssociationMap< edm::OneToManyWithQualityGeneric< TrackingParticleCollection, edm::View< reco::Track >, double > >::values().
internal_transient_map_type edm::AssociationMap< Tag >::transientMap_ [mutable, private] |
transient reference map
Definition at line 155 of file AssociationMap.h.
Referenced by edm::AssociationMap< edm::OneToManyWithQualityGeneric< TrackingParticleCollection, edm::View< reco::Track >, double > >::clear(), edm::AssociationMap< edm::OneToManyWithQualityGeneric< TrackingParticleCollection, edm::View< reco::Track >, double > >::erase(), and edm::AssociationMap< edm::OneToManyWithQualityGeneric< TrackingParticleCollection, edm::View< reco::Track >, double > >::operator[]().