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 82 of file IntermediateHitDoublets.h.

Member Typedef Documentation

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

Definition at line 86 of file IntermediateHitDoublets.h.

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

Definition at line 84 of file IntermediateHitDoublets.h.

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

Definition at line 85 of file IntermediateHitDoublets.h.

Constructor & Destructor Documentation

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

Definition at line 88 of file IntermediateHitDoublets.h.

88 : hitSets_(hst), iter_(iter) {}
internal_iterator_type iter_
const HitSetType * hitSets_

Member Function Documentation

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

Definition at line 106 of file IntermediateHitDoublets.h.

References operator==().

106 { return !operator==(other); }
bool operator==(const const_iterator &other) const
template<typename ValueType , typename HitSetType >
value_type ihd::const_iterator< ValueType, HitSetType >::operator* ( void  ) const
inline

Definition at line 90 of file IntermediateHitDoublets.h.

90  {
91  return value_type(&(iter_->region()),
92  &(iter_->layerHitMapCache()),
93  hitSets_,
94  hitSets_->layerSetsBegin() + iter_->layerSetBeginIndex(),
95  hitSets_->layerSetsBegin() + iter_->layerSetEndIndex());
96  }
internal_iterator_type iter_
const HitSetType * hitSets_
template<typename ValueType , typename HitSetType >
const_iterator& ihd::const_iterator< ValueType, HitSetType >::operator++ ( void  )
inline

Definition at line 98 of file IntermediateHitDoublets.h.

98 { ++iter_; return *this; }
internal_iterator_type iter_
template<typename ValueType , typename HitSetType >
const_iterator ihd::const_iterator< ValueType, HitSetType >::operator++ ( int  )
inline

Definition at line 99 of file IntermediateHitDoublets.h.

References clone().

99  {
100  const_iterator clone(*this);
101  ++iter_;
102  return clone;
103  }
internal_iterator_type iter_
const_iterator(const HitSetType *hst, internal_iterator_type iter)
TEveGeoShape * clone(const TEveElement *element, TEveElement *parent)
Definition: eve_macros.cc:135
template<typename ValueType , typename HitSetType >
bool ihd::const_iterator< ValueType, HitSetType >::operator== ( const const_iterator< ValueType, HitSetType > &  other) const
inline

Definition at line 105 of file IntermediateHitDoublets.h.

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

105 { return iter_ == other.iter_; }
internal_iterator_type iter_

Member Data Documentation

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

Definition at line 109 of file IntermediateHitDoublets.h.

template<typename ValueType , typename HitSetType >
internal_iterator_type ihd::const_iterator< ValueType, HitSetType >::iter_
private