CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Public Types | Public Member Functions | Static Public Member Functions | Private Member Functions | Private Attributes | Friends
edm::RegionIndex< T > Class Template Reference

#include <LazyGetter.h>

Public Types

typedef std::vector< T >
::const_iterator 
const_iterator
 
typedef std::pair
< const_iterator,
const_iterator
pair_iterator
 

Public Member Functions

const_iterator begin () const
 Get begin iterator. More...
 
const_iterator end () const
 Get off the end iterator. More...
 
pair_iterator find (uint32_t id) const
 Get range of T on on det. More...
 
uint32_t finish () const
 Get off-the-end finish index. More...
 
uint32_t region () const
 Get region number. More...
 
 RegionIndex ()
 Default constructor. More...
 
 RegionIndex (uint32_t region, uint32_t start, uint32_t finish, const LazyGetter< T > *theLazyGetter)
 Constructor. More...
 
uint32_t start () const
 Get start index. More...
 
bool unpacked () const
 Get unpacking status. More...
 
RegionIndex< T > & updateLazyGetter (const LazyGetter< T > *newLazyGetter)
 Update the pointer to the lazyGetter. More...
 

Static Public Member Functions

static short Class_Version ()
 

Private Member Functions

void finish (uint32_t)
 Set of-the-end finish index. More...
 
void start (uint32_t)
 Set start index. More...
 
void unpacked (bool)
 Set unpacking status. More...
 

Private Attributes

uint32_t finish_
 
const LazyGetter< T > * getter_
 
uint32_t region_
 
uint32_t start_
 
bool unpacked_
 

Friends

class LazyAdapter< T >
 

Detailed Description

template<class T>
class edm::RegionIndex< T >

Definition at line 40 of file LazyGetter.h.

Member Typedef Documentation

template<class T>
typedef std::vector<T>::const_iterator edm::RegionIndex< T >::const_iterator

Definition at line 46 of file LazyGetter.h.

template<class T>
typedef std::pair<const_iterator,const_iterator> edm::RegionIndex< T >::pair_iterator

Definition at line 47 of file LazyGetter.h.

Constructor & Destructor Documentation

template<class T >
edm::RegionIndex< T >::RegionIndex ( )
inline

Default constructor.

Definition at line 104 of file LazyGetter.h.

104  :
105  region_(0),
106  start_(0),
107  finish_(0),
108  unpacked_(false),
109  getter_(NULL)
110  {}
#define NULL
Definition: scimark2.h:8
uint32_t finish_
Definition: LazyGetter.h:95
uint32_t region_
Definition: LazyGetter.h:93
const LazyGetter< T > * getter_
Definition: LazyGetter.h:97
uint32_t start_
Definition: LazyGetter.h:94
template<class T >
edm::RegionIndex< T >::RegionIndex ( uint32_t  region,
uint32_t  start,
uint32_t  finish,
const LazyGetter< T > *  theLazyGetter 
)
inline

Constructor.

Definition at line 114 of file LazyGetter.h.

114  :
115  region_(region),
116  start_(start),
117  finish_(finish),
118  unpacked_(false),
119  getter_(theLazyGetter)
120  {}
uint32_t finish_
Definition: LazyGetter.h:95
uint32_t region_
Definition: LazyGetter.h:93
uint32_t finish() const
Get off-the-end finish index.
Definition: LazyGetter.h:140
const LazyGetter< T > * getter_
Definition: LazyGetter.h:97
uint32_t start_
Definition: LazyGetter.h:94
uint32_t region() const
Get region number.
Definition: LazyGetter.h:125
uint32_t start() const
Get start index.
Definition: LazyGetter.h:133

Member Function Documentation

template<class T >
RegionIndex< T >::const_iterator edm::RegionIndex< T >::begin ( void  ) const
inline

Get begin iterator.

Definition at line 180 of file LazyGetter.h.

Referenced by SiStripRecHitConverterAlgorithm::run(), and MeasurementTrackerImpl::updateStrips().

181  {
182  //check pointer here and throw if null
183  return getter_->begin_record()+start_;
184  }
const LazyGetter< T > * getter_
Definition: LazyGetter.h:97
uint32_t start_
Definition: LazyGetter.h:94
template<class T>
static short edm::RegionIndex< T >::Class_Version ( )
inlinestatic

Definition at line 80 of file LazyGetter.h.

82 :
83 
template<class T >
RegionIndex< T >::const_iterator edm::RegionIndex< T >::end ( void  ) const
inline

Get off the end iterator.

Definition at line 189 of file LazyGetter.h.

Referenced by Types.LuminosityBlockRange::cppID(), Types.EventRange::cppID(), and MeasurementTrackerImpl::updateStrips().

190  {
191  //check pointer here and throw if null
192  return getter_->begin_record()+finish_;
193  }
uint32_t finish_
Definition: LazyGetter.h:95
const LazyGetter< T > * getter_
Definition: LazyGetter.h:97
template<class T >
RegionIndex< T >::pair_iterator edm::RegionIndex< T >::find ( uint32_t  id) const
inline

Get range of T on on det.

Definition at line 207 of file LazyGetter.h.

References begin, and end.

Referenced by BeautifulSoup.Tag::__getattr__(), and BeautifulSoup.Tag::firstText().

208  {
209  return std::equal_range(begin(),end(),id);
210  }
const_iterator end() const
Get off the end iterator.
Definition: LazyGetter.h:189
const_iterator begin() const
Get begin iterator.
Definition: LazyGetter.h:180
template<class T >
uint32_t edm::RegionIndex< T >::finish ( ) const
inline

Get off-the-end finish index.

Definition at line 140 of file LazyGetter.h.

Referenced by progressbar.ProgressBar::__next__(), edm::LazyAdapter< T >::operator()(), and SiStripRecHitConverterAlgorithm::run().

141  {
142  return finish_;
143  }
uint32_t finish_
Definition: LazyGetter.h:95
template<class T >
void edm::RegionIndex< T >::finish ( uint32_t  newfinish)
inlineprivate

Set of-the-end finish index.

Definition at line 164 of file LazyGetter.h.

Referenced by progressbar.ProgressBar::__next__().

165  {
166  finish_=newfinish;
167  }
uint32_t finish_
Definition: LazyGetter.h:95
template<class T >
uint32_t edm::RegionIndex< T >::region ( ) const
inline

Get region number.

Definition at line 125 of file LazyGetter.h.

Referenced by edm::LazyAdapter< T >::operator()().

126  {
127  return region_;
128  }
uint32_t region_
Definition: LazyGetter.h:93
template<class T >
uint32_t edm::RegionIndex< T >::start ( ) const
inline
template<class T >
void edm::RegionIndex< T >::start ( uint32_t  newstart)
inlineprivate

Set start index.

Definition at line 156 of file LazyGetter.h.

Referenced by progressbar.ProgressBar::__next__(), Types.LuminosityBlockRange::cppID(), and Types.EventRange::cppID().

157  {
158  start_=newstart;
159  }
uint32_t start_
Definition: LazyGetter.h:94
template<class T >
bool edm::RegionIndex< T >::unpacked ( ) const
inline

Get unpacking status.

Definition at line 148 of file LazyGetter.h.

Referenced by edm::LazyAdapter< T >::operator()().

149  {
150  return unpacked_;
151  }
template<class T >
void edm::RegionIndex< T >::unpacked ( bool  newunpacked)
inlineprivate

Set unpacking status.

Definition at line 172 of file LazyGetter.h.

173  {
174  unpacked_=newunpacked;
175  }
template<class T >
RegionIndex< T > & edm::RegionIndex< T >::updateLazyGetter ( const LazyGetter< T > *  newLazyGetter)
inline

Update the pointer to the lazyGetter.

Definition at line 198 of file LazyGetter.h.

Referenced by edm::LazyAdapter< T >::operator()(), and edm::UpdateGetterAdapter< T >::operator()().

199  {
200  getter_ = newGetter;
201  return *this;
202  }
const LazyGetter< T > * getter_
Definition: LazyGetter.h:97

Friends And Related Function Documentation

template<class T>
friend class LazyAdapter< T >
friend

Definition at line 42 of file LazyGetter.h.

Member Data Documentation

template<class T>
uint32_t edm::RegionIndex< T >::finish_
private

Definition at line 95 of file LazyGetter.h.

template<class T>
const LazyGetter<T>* edm::RegionIndex< T >::getter_
private

Definition at line 97 of file LazyGetter.h.

template<class T>
uint32_t edm::RegionIndex< T >::region_
private

Definition at line 93 of file LazyGetter.h.

template<class T>
uint32_t edm::RegionIndex< T >::start_
private

Definition at line 94 of file LazyGetter.h.

template<class T>
bool edm::RegionIndex< T >::unpacked_
private

Definition at line 96 of file LazyGetter.h.