CMS 3D CMS Logo

List of all members | Public Types | Public Member Functions | Private Attributes
ihd::const_iterator< ValueType, HitSetType > Class Template Reference

#include <IntermediateHitDoublets.h>

Public Types

using difference_type = internal_iterator_type::difference_type
 
using internal_iterator_type = typename std::vector< RegionIndex >::const_iterator
 
using value_type = ValueType
 

Public Member Functions

 const_iterator (const HitSetType *hst, internal_iterator_type iter)
 
bool operator!= (const const_iterator &other) const
 
value_type operator* () const
 
const_iteratoroperator++ ()
 
const_iterator operator++ (int)
 
bool operator== (const const_iterator &other) const
 

Private Attributes

const HitSetType * hitSets_
 
internal_iterator_type iter_
 

Detailed Description

template<typename ValueType, typename HitSetType>
class ihd::const_iterator< ValueType, HitSetType >

Helper class providing a generic iterator to loop over TrackingRegions of IntermediateHitDoublets, IntermediateHitTriplets, or RegionsSeedingHitSets

Template Parameters
ValueTypeType to be returned by operator*() (should be something inexpensive)
HitSetTypeType of the holder of data (currently IntermediateHitDoublets, IntermediateHitTriplets, or RegionsSeedingHitSets)

Definition at line 85 of file IntermediateHitDoublets.h.

Member Typedef Documentation

◆ difference_type

template<typename ValueType , typename HitSetType >
using ihd::const_iterator< ValueType, HitSetType >::difference_type = internal_iterator_type::difference_type

Definition at line 89 of file IntermediateHitDoublets.h.

◆ internal_iterator_type

template<typename ValueType , typename HitSetType >
using ihd::const_iterator< ValueType, HitSetType >::internal_iterator_type = typename std::vector<RegionIndex>::const_iterator

Definition at line 87 of file IntermediateHitDoublets.h.

◆ value_type

template<typename ValueType , typename HitSetType >
using ihd::const_iterator< ValueType, HitSetType >::value_type = ValueType

Definition at line 88 of file IntermediateHitDoublets.h.

Constructor & Destructor Documentation

◆ const_iterator()

template<typename ValueType , typename HitSetType >
ihd::const_iterator< ValueType, HitSetType >::const_iterator ( const HitSetType *  hst,
internal_iterator_type  iter 
)
inline

Definition at line 91 of file IntermediateHitDoublets.h.

91 : hitSets_(hst), iter_(iter) {}

Member Function Documentation

◆ operator!=()

template<typename ValueType , typename HitSetType >
bool ihd::const_iterator< ValueType, HitSetType >::operator!= ( const const_iterator< ValueType, HitSetType > &  other) const
inline

◆ operator*()

template<typename ValueType , typename HitSetType >
value_type ihd::const_iterator< ValueType, HitSetType >::operator* ( void  ) const
inline

Definition at line 93 of file IntermediateHitDoublets.h.

93  {
94  return value_type(&(iter_->region()),
95  &(iter_->layerHitMapCache()),
96  hitSets_,
97  hitSets_->layerSetsBegin() + iter_->layerSetBeginIndex(),
98  hitSets_->layerSetsBegin() + iter_->layerSetEndIndex());
99  }

References ihd::const_iterator< ValueType, HitSetType >::hitSets_, and ihd::const_iterator< ValueType, HitSetType >::iter_.

◆ operator++() [1/2]

template<typename ValueType , typename HitSetType >
const_iterator& ihd::const_iterator< ValueType, HitSetType >::operator++ ( void  )
inline

Definition at line 101 of file IntermediateHitDoublets.h.

101  {
102  ++iter_;
103  return *this;
104  }

References ihd::const_iterator< ValueType, HitSetType >::iter_.

◆ operator++() [2/2]

template<typename ValueType , typename HitSetType >
const_iterator ihd::const_iterator< ValueType, HitSetType >::operator++ ( int  )
inline

Definition at line 105 of file IntermediateHitDoublets.h.

105  {
106  const_iterator clone(*this);
107  ++iter_;
108  return clone;
109  }

References clone(), and ihd::const_iterator< ValueType, HitSetType >::iter_.

◆ operator==()

template<typename ValueType , typename HitSetType >
bool ihd::const_iterator< ValueType, HitSetType >::operator== ( const const_iterator< ValueType, HitSetType > &  other) const
inline

Member Data Documentation

◆ hitSets_

template<typename ValueType , typename HitSetType >
const HitSetType* ihd::const_iterator< ValueType, HitSetType >::hitSets_
private

◆ iter_

template<typename ValueType , typename HitSetType >
internal_iterator_type ihd::const_iterator< ValueType, HitSetType >::iter_
private
clone
TEveGeoShape * clone(const TEveElement *element, TEveElement *parent)
Definition: eve_macros.cc:135
ihd::const_iterator::operator==
bool operator==(const const_iterator &other) const
Definition: IntermediateHitDoublets.h:111
ihd::const_iterator::value_type
ValueType value_type
Definition: IntermediateHitDoublets.h:88
ihd::const_iterator::const_iterator
const_iterator(const HitSetType *hst, internal_iterator_type iter)
Definition: IntermediateHitDoublets.h:91
trackingPlots.other
other
Definition: trackingPlots.py:1465
ihd::const_iterator::iter_
internal_iterator_type iter_
Definition: IntermediateHitDoublets.h:116
ihd::const_iterator::hitSets_
const HitSetType * hitSets_
Definition: IntermediateHitDoublets.h:115