24 #ifndef PPL_Ptr_Iterator_defs_hh
25 #define PPL_Ptr_Iterator_defs_hh 1
32 namespace Implementation {
34 template<
typename P,
typename Q>
35 bool operator==(
const Ptr_Iterator<P>& x,
const Ptr_Iterator<Q>& y);
37 template<
typename P,
typename Q>
38 bool operator!=(
const Ptr_Iterator<P>& x,
const Ptr_Iterator<Q>& y);
40 template<
typename P,
typename Q>
41 bool operator<(const Ptr_Iterator<P>& x,
const Ptr_Iterator<Q>& y);
43 template<
typename P,
typename Q>
44 bool operator<=(const Ptr_Iterator<P>& x,
const Ptr_Iterator<Q>& y);
46 template<
typename P,
typename Q>
47 bool operator>(
const Ptr_Iterator<P>& x,
const Ptr_Iterator<Q>& y);
49 template<
typename P,
typename Q>
50 bool operator>=(
const Ptr_Iterator<P>& x,
const Ptr_Iterator<Q>& y);
52 template<
typename P,
typename Q>
53 typename Ptr_Iterator<P>::difference_type
54 operator-(
const Ptr_Iterator<P>& x,
const Ptr_Iterator<Q>& y);
57 Ptr_Iterator<P>
operator+(
typename Ptr_Iterator<P>::difference_type m,
58 const Ptr_Iterator<P>& y);
64 #ifdef PPL_DOXYGEN_INCLUDE_IMPLEMENTATION_DETAILS
65 #endif // defined(PPL_DOXYGEN_INCLUDE_IMPLEMENTATION_DETAILS)
69 :
public std::iterator<typename std::iterator_traits<P>::iterator_category,
70 typename std::iterator_traits<P>::value_type,
71 typename std::iterator_traits<P>::difference_type,
72 typename std::iterator_traits<P>::pointer,
73 typename std::iterator_traits<P>::reference> {
76 typedef typename std::iterator_traits<P>::reference
reference;
77 typedef typename std::iterator_traits<P>::pointer
pointer;
99 reference
operator[](
const difference_type m)
const;
133 const P&
base()
const;
135 template <
typename Q,
typename R>
139 template <
typename Q,
typename R>
143 template<
typename Q,
typename R>
144 friend bool Parma_Polyhedra_Library::Implementation::
147 template<
typename Q,
typename R>
148 friend bool Parma_Polyhedra_Library::Implementation::
151 template<
typename Q,
typename R>
155 template<
typename Q,
typename R>
159 template<
typename Q,
typename R>
165 Parma_Polyhedra_Library::Implementation::
172 #endif // !defined(PPL_Ptr_Iterator_defs_hh)
pointer operator->() const
Indirect member selector.
Ptr_Iterator< P >::difference_type operator-(const Ptr_Iterator< P > &x, const Ptr_Iterator< Q > &y)
bool operator>(const Ptr_Iterator< P > &x, const Ptr_Iterator< Q > &y)
reference operator[](const difference_type m) const
Subscript operator.
Ptr_Iterator & operator--()
Prefix decrement operator.
A class to define STL const and non-const iterators from pointer types.
bool operator>=(const Ptr_Iterator< P > &x, const Ptr_Iterator< Q > &y)
Ptr_Iterator()
Default constructor: no guarantees.
difference_type operator-(const Ptr_Iterator &y) const
Returns the difference between *this and y.
std::iterator_traits< P >::reference reference
reference operator*() const
Dereference operator.
P p
The base pointer implementing the iterator.
bool operator==(const EList_Iterator< T > &x, const EList_Iterator< T > &y)
Returns true if and only if x and y are equal.
bool operator!=(const EList_Iterator< T > &x, const EList_Iterator< T > &y)
Returns true if and only if x and y are different.
Ptr_Iterator & operator++()
Prefix increment operator.
std::iterator_traits< P >::pointer pointer
Ptr_Iterator & operator-=(const difference_type m)
Assignment-decrement operator.
Ptr_Iterator & operator+=(const difference_type m)
Assignment-increment operator.
The entire library is confined to this namespace.
Ptr_Iterator operator+(const difference_type m) const
Returns the sum of *this and m.
std::iterator_traits< P >::difference_type difference_type
Ptr_Iterator< P > operator+(typename Ptr_Iterator< P >::difference_type m, const Ptr_Iterator< P > &y)
const P & base() const
Returns the hidden pointer.