75 template<
class ContainerType>
86 typename ContainerType::iterator
begin_;
89 typename ContainerType::iterator
end_;
92 typename ContainerType::iterator
iter_;
97 typename ContainerType::iterator
fulcrum_;
105 typedef typename ContainerType::value_type
value_type;
115 typedef typename ContainerType::iterator
iterator;
119 typedef typename ContainerType::reference
reference;
128 inline explicit Circulator(ContainerType& container);
131 inline Circulator(
const iterator& begin,
const iterator& end);
144 inline size_type
size()
const;
164 inline reference
next()
const;
167 inline reference
prev()
const;
212 inline difference_type
operator-
Circulator()
Construct null.
bool operator!=(const Circulator< ContainerType > &c) const
Check for inequality of this iterator with another iterator that.
ContainerType::difference_type difference_type
The type that can represent the difference between any two.
void setIteratorToFulcrum()
Set the iterator to the current position of the fulcrum.
Circulator< ContainerType > & operator--()
Prefix decrement. Decrements the iterator.
ContainerType::iterator end_
Iterator pointing to the end of the container.
ContainerType::iterator iterator
Random access iterator for traversing ContainerType.
difference_type nRotations() const
Return the distance between the iterator and the fulcrum. This is.
direction
Direction type enumeration.
void setFulcrumToIterator()
Set the fulcrum to the current position of the iterator.
size_type size() const
Return the range of the iterator.
ContainerType::iterator fulcrum_
Iterator holding the location of the fulcrum (start and end) of.
reference next() const
Dereference the next iterator and return.
bool operator==(const Circulator< ContainerType > &c) const
Check for equality of this iterator with another iterator that.
reference operator*() const
Dereference the iterator and return.
ContainerType::size_type size_type
The type that can represent the size of ContainerType.
void operator=(const Circulator< ContainerType > &)
Assignment operator for Circulators that operate on the same.
graph_traits< Graph >::vertices_size_type size_type
ContainerType::value_type value_type
Type of values ContainerType contains.
Circulator< ContainerType > & operator++()
Prefix increment. Increments the iterator.
bool circulate(const CirculatorBase::direction dir=CirculatorBase::direction::none)
Circulate around the list in the given direction.
Walks over a container as if it were circular. The container must have the following members defined:...
reference operator()() const
Dereference the iterator and return.
ContainerType::iterator iter_
Random access iterator for traversing ContainerType.
reference prev() const
Dereference the previous iterator and return.
Base class for circulators.
ContainerType::reference reference
Type that can be used for storing into.
const dimensionedScalar c
Speed of light in a vacuum.
ContainerType::iterator begin_
Iterator pointing to the beginning of the container.