Documentation
template<typename Iter, typename Op>
class TiledArray::detail::UnaryTransformIterator< Iter, Op >
Unary transform iterator.
This iterator holds an iterator that is transformed when dereferenced with a unary transform object that is provided by the user. The iterator dereferences to the result type of the transform operations.
- Template Parameters
-
Iter The base iterator type of the transform iterator. Op The transform operator type.
Definition at line 252 of file transform_iterator.h.
Public Types | |
typedef ptrdiff_t | difference_type |
Difference type. More... | |
typedef madness::detail::result_of< Op >::type | value_type |
Iterator dereference value type. More... | |
typedef PointerProxy< value_type > | pointer |
Pointer type to iterator value. More... | |
typedef value_type | reference |
Reference type to iterator value. More... | |
typedef std::input_iterator_tag | iterator_category |
Iterator category type. More... | |
typedef UnaryTransformIterator< Iter, Op > | this_type |
This object type. More... | |
typedef Iter | base_iterator |
The base iterator type. More... | |
Public Member Functions | |
UnaryTransformIterator (Iter it, Op op=Op()) | |
Constructor. More... | |
UnaryTransformIterator (const this_type &other) | |
Copy constructor. More... | |
template<typename It > | |
UnaryTransformIterator (const UnaryTransformIterator< It, Op > &other) | |
Copy conversion constructor. More... | |
this_type & | operator= (const this_type &other) |
Copy operator. More... | |
template<typename It > | |
this_type & | operator= (const UnaryTransformIterator< It, Op > &other) |
Copy conversion operator. More... | |
this_type & | operator++ () |
Prefix increment operator. More... | |
this_type | operator++ (int) |
Post-fix increment operator. More... | |
template<typename It > | |
bool | operator== (const UnaryTransformIterator< It, Op > &other) const |
Equality operator. More... | |
template<typename It > | |
bool | operator!= (const UnaryTransformIterator< It, Op > &other) const |
Inequality operator. More... | |
reference | operator* () const |
Dereference operator. More... | |
pointer | operator-> () const |
Arrow dereference operator. More... | |
base_iterator | base () const |
Base iterator accessor. More... | |
Friends | |
template<typename , typename > | |
class | UnaryTransformIterator |
Member Typedef Documentation
◆ base_iterator
typedef Iter TiledArray::detail::UnaryTransformIterator< Iter, Op >::base_iterator |
The base iterator type.
Definition at line 267 of file transform_iterator.h.
◆ difference_type
typedef ptrdiff_t TiledArray::detail::UnaryTransformIterator< Iter, Op >::difference_type |
Difference type.
Definition at line 259 of file transform_iterator.h.
◆ iterator_category
typedef std::input_iterator_tag TiledArray::detail::UnaryTransformIterator< Iter, Op >::iterator_category |
Iterator category type.
Definition at line 265 of file transform_iterator.h.
◆ pointer
typedef PointerProxy<value_type> TiledArray::detail::UnaryTransformIterator< Iter, Op >::pointer |
Pointer type to iterator value.
Definition at line 262 of file transform_iterator.h.
◆ reference
typedef value_type TiledArray::detail::UnaryTransformIterator< Iter, Op >::reference |
Reference type to iterator value.
Definition at line 263 of file transform_iterator.h.
◆ this_type
typedef UnaryTransformIterator<Iter, Op> TiledArray::detail::UnaryTransformIterator< Iter, Op >::this_type |
This object type.
Definition at line 266 of file transform_iterator.h.
◆ value_type
typedef madness::detail::result_of<Op>::type TiledArray::detail::UnaryTransformIterator< Iter, Op >::value_type |
Iterator dereference value type.
Definition at line 261 of file transform_iterator.h.
Constructor & Destructor Documentation
◆ UnaryTransformIterator() [1/3]
|
inline |
Constructor.
- Parameters
-
it The base iterator op The transform operator
Definition at line 273 of file transform_iterator.h.
◆ UnaryTransformIterator() [2/3]
|
inline |
Copy constructor.
- Parameters
-
other The transform iterator to copy
Definition at line 278 of file transform_iterator.h.
◆ UnaryTransformIterator() [3/3]
|
inline |
Copy conversion constructor.
This constructor allows copying when the base iterators are implicitly convertible with each other.
- Template Parameters
-
It An iterator type that is implicitly convertible to base_iterator
type.
- Parameters
-
other The transform iterator to copy
- Note
- The operation type must be the same for both transform iterators.
Definition at line 290 of file transform_iterator.h.
Member Function Documentation
◆ base()
|
inline |
Base iterator accessor.
- Returns
- A copy of the base iterator.
Definition at line 375 of file transform_iterator.h.
◆ operator!=()
|
inline |
Inequality operator.
- Template Parameters
-
It An iterator type that is implicitly convertible to base_iterator
type.
- Parameters
-
other The iterator to compare to this iterator.
- Returns
- True when the base iterators are not equal to each other, otherwise false.
Definition at line 357 of file transform_iterator.h.
◆ operator*()
|
inline |
Dereference operator.
- Returns
- A transformed copy of the current base iterator value.
Definition at line 364 of file transform_iterator.h.
◆ operator++() [1/2]
|
inline |
Prefix increment operator.
- Returns
- A reference to this object after it has been incremented.
Definition at line 323 of file transform_iterator.h.
◆ operator++() [2/2]
|
inline |
Post-fix increment operator.
- Returns
- A copy of this object before it is incremented.
Definition at line 331 of file transform_iterator.h.
◆ operator->()
|
inline |
Arrow dereference operator.
- Returns
- A pointer to a transformed copy of the current base iterator value.
Definition at line 370 of file transform_iterator.h.
◆ operator=() [1/2]
|
inline |
Copy operator.
- Parameters
-
other The transform iterator to copy
- Returns
- A reference to this object
Definition at line 297 of file transform_iterator.h.
◆ operator=() [2/2]
|
inline |
Copy conversion operator.
This operator allows copying when the base iterators are implicitly convertible with each other.
- Template Parameters
-
It An iterator type that is implicitly convertible to base_iterator
.
- Parameters
-
other The transform iterator to copy
- Note
- The operation type must be the same for both transform iterators.
Definition at line 313 of file transform_iterator.h.
◆ operator==()
|
inline |
Equality operator.
- Template Parameters
-
It An iterator type that is implicitly convertible to base_iterator
type.
- Parameters
-
other The iterator to compare to this iterator.
- Returns
- True when the base iterators are equal to each other, otherwise false.
Definition at line 345 of file transform_iterator.h.
Friends And Related Function Documentation
◆ UnaryTransformIterator
|
friend |
Definition at line 256 of file transform_iterator.h.
The documentation for this class was generated from the following file:
- TiledArray/transform_iterator.h