My Project
 All Classes Files Functions Variables Enumerations Enumerator Friends Macros Pages
RegCoordRange.h
Go to the documentation of this file.
1 #ifndef GCP_UTIL_REGCOORDRANGE_H
2 #define GCP_UTIL_REGCOORDRANGE_H
3 
11 #include "gcp/util/common/CoordRange.h"
12 #include "gcp/util/common/Range.h"
13 #include "gcp/util/common/RegDescription.h"
14 
15 #include <vector>
16 
17 namespace gcp {
18  namespace util {
19 
24  class RegCoordRange {
25  public:
26 
31 
35  virtual ~RegCoordRange();
36 
40  inline unsigned currentElement() {
41  return iElCurrent_;
42  }
43 
44  inline unsigned currentSlot() {
45  return iElCurrent_ + iSlotOffset_;
46  }
47 
51  const RegCoordRange& operator++();
52 
56  void reset();
57 
61  bool isEnd();
62 
66  friend std::ostream& operator<<(std::ostream& os, RegCoordRange& range);
67 
68  private:
69 
70  int iSlotOffset_;
71  unsigned iElCurrent_;
72  std::vector<Range<unsigned> > ranges_;
73  std::vector<Range<unsigned> >::iterator iRange_;
74 
75  }; // End class RegCoordRange
76 
77  } // End namespace util
78 } // End namespace gcp
79 
80 
81 
82 
83 #endif // End #ifndef GCP_UTIL_REGCOORDRANGE_H
const RegCoordRange & operator++()
Definition: RegCoordRange.cc:53
unsigned currentElement()
Definition: RegCoordRange.h:40
Definition: CoordRange.h:20
friend std::ostream & operator<<(std::ostream &os, RegCoordRange &range)
Definition: RegCoordRange.h:24
void reset()
Definition: RegCoordRange.cc:36
RegCoordRange(RegDescription &reg, CoordRange &range)
Definition: RegCoordRange.cc:11
virtual ~RegCoordRange()
Definition: RegCoordRange.cc:30
bool isEnd()
Definition: RegCoordRange.cc:45
Definition: RegDescription.h:26