Om
iterator_pair_source.hpp
Go to the documentation of this file.
1 
15 #ifndef Om_Source_IteratorPairSource_
16 
17  #define Om_Source_IteratorPairSource_ \
18  Om::Source::IteratorPairSource
19 
21 
22 namespace Om {
23 
24  namespace Source {
25 
26  // MARK: - Om::Source::IteratorPairSource
27 
32  template <
33  typename ThisItem,
34  typename ThisIterator
35  >
37  public DefaultSource<
38  ThisItem,
39  IteratorPairSource<
40  ThisItem,
41  ThisIterator
42  >
43  > {
44 
45  public: // MARK: public (non-static)
46 
54  ThisIterator theCurrent,
55  ThisIterator const theEnd
56  );
57 
59 
60  virtual ThisItem & operator *() const;
61 
62  using DefaultSource<
63  ThisItem,
65  ThisItem,
66  ThisIterator
67  >
68  >::Equals;
69 
70  bool Equals(IteratorPairSource const &) const;
71 
72  void End();
73 
74  virtual bool operator !() const;
75 
76  virtual void Pop();
77 
79 
80  private: // MARK: private (non-static)
81 
86  ThisIterator thisCurrent;
87 
92  ThisIterator thisEnd;
93 
94  };
95 
96  // MARK: - Om::Source::
97 
98  template <
99  typename TheItem,
100  typename TheIterator
101  >
104  TheItem,
105  TheIterator
106  > const &,
108  TheItem,
109  TheIterator
110  > const &
111  );
112 
113  template <
114  typename TheItem,
115  typename TheIterator
116  >
119  TheItem,
120  TheIterator
121  > const &,
123  TheItem,
124  TheIterator
125  > const &
126  );
127 
128  }
129 
130 }
131 
132 namespace boost {
133 
134  // MARK: - boost::
135 
136  template <
137  typename TheItem,
138  typename TheIterator
139  >
140  void swap(
142  TheItem,
143  TheIterator
144  > &,
146  TheItem,
147  TheIterator
148  > &
149  );
150 
151 }
152 
154 
155 #endif
A partial implementation of Source.
A Source adapter for a start and end input iterator pair.
virtual bool operator!() const
IteratorPairSource & operator=(IteratorPairSource)
void Swap(IteratorPairSource &)
virtual ThisItem & operator*() const
virtual void Pop()
Pops the current item.
IteratorPairSource(ThisIterator theCurrent, ThisIterator const theEnd)
ThisIterator thisEnd
The end input iterator.
bool Equals(IteratorPairSource const &) const
ThisIterator thisCurrent
The current input iterator.
Om header file.
bool operator==(CodePointSource< TheCodeUnitIterator > const &, CodePointSource< TheCodeUnitIterator > const &)
bool operator!=(CodePointSource< TheCodeUnitIterator > const &, CodePointSource< TheCodeUnitIterator > const &)
The Om library.
Definition: code_point.hpp:26
void swap(Om::Language::Expression &, Om::Language::Expression &)