Dynamic cast iterator for polymorphic pointer vectors.The CastIterator class is part of the PtrVector class and represent a forward iterator over all elements of type C contained in a range of elements of type T, where C is a type derived from T.
More...
#include <PtrVector.h>
template<typename T, typename D = PtrDelete, typename G = OptimalGrowth>
template<typename C>
class blaze::PtrVector< T, D, G >::CastIterator< C >
Dynamic cast iterator for polymorphic pointer vectors.
The CastIterator class is part of the PtrVector class and represent a forward iterator over all elements of type C contained in a range of elements of type T, where C is a type derived from T.
class A { ... };
class B : public class A { ... };
...
- Note
- Using a CastIterator is computationally more expensive than using a standard iterator over all elements contained in the vector.
template<typename T , typename D , typename G >
template<typename C >
Standard constructor for CastIterator.
- Parameters
-
begin | The beginning of the element range. |
end | The end of the element range. |
template<typename T , typename D , typename G >
template<typename C >
template<typename Other >
Conversion constructor from different CastIterator instances.
- Parameters
-
template<typename T , typename D , typename G >
template<typename C >
Direct access to the current memory location of the cast iterator.
- Returns
- Pointer to the current memory location.
template<typename T , typename D , typename G >
template<typename C >
Returns a handle to the element at the current iterator position.
- Returns
- Handle to the element at the current iterator position.
template<typename T , typename D , typename G >
template<typename C >
Pre-increment operator.
- Returns
- Reference to the incremented cast iterator.
template<typename T , typename D , typename G >
template<typename C >
Post-increment operator.
- Returns
- The incremented cast iterator.
template<typename T , typename D , typename G >
template<typename C >
Direct access to the element at the current iterator position.
- Returns
- Reference to the element at the current iterator position.
template<typename T , typename D , typename G >
template<typename C >
Direct access to the final memory location of the cast iterator.
- Returns
- Pointer to the final memory location.
The documentation for this class was generated from the following file: