PLaSK library
|
Polymorphic, forward iterator which allow to get index of current position. More...
#include <plask/utils/iterators.hpp>
Public Member Functions | |
PolymorphicForwardIteratorWithIndex (ImplT *impl=nullptr) | |
Construct iterator which holds given implementation object. | |
std::size_t | getIndex () const |
Get index for current iterator state. | |
Public Member Functions inherited from plask::PolymorphicForwardIterator< ImplT > | |
PolymorphicForwardIterator (ImplT *impl=nullptr) | |
Construct iterator which holds given implementation object. | |
PolymorphicForwardIterator (const PolymorphicForwardIterator &src) | |
Copy constructor. | |
PolymorphicForwardIterator (PolymorphicForwardIterator &&src)=default | |
Move constructor. | |
void | swap (PolymorphicForwardIterator &to_swap) noexcept |
Swap values of this and to_swap . | |
PolymorphicForwardIterator & | operator= (const PolymorphicForwardIterator &src) |
PolymorphicForwardIterator & | operator= (PolymorphicForwardIterator &&src)=default |
Additional Inherited Members | |
Protected Attributes inherited from plask::PolymorphicForwardIterator< ImplT > | |
std::unique_ptr< ImplT > | impl |
Polymorphic, forward iterator which allow to get index of current position.
Hold and delegate all calls to implementation object which is a instantiation of PolymorphicForwardIteratorWithIndexImpl template.
ImplT | instantiation of PolymorphicForwardIteratorWithIndexImpl |
Definition at line 200 of file iterators.hpp.
|
inline |
Construct iterator which holds given implementation object.
impl | Implementation object. It will be delete by constructor of this. If it is nullptr you should not call any methods of this before assign. |
Definition at line 207 of file iterators.hpp.
|
inline |
Get index for current iterator state.
Definition at line 213 of file iterators.hpp.