STIR
6.2.0
|
Helper class for NestedIterator when the 1st level iterator refers to an ordinary iterator for the 2nd level iterator. More...
#include "stir/NestedIteratorHelpers.h"
Public Types | |
typedef RestIterT | rest_iter_type |
typedef storing the type of the 2nd level iterator | |
Public Member Functions | |
RestIterT | begin (const TopLevelIterT &iter) const |
function to get the first 2nd level iterator for a top-level iterator More... | |
RestIterT | end (const TopLevelIterT &iter) const |
function to get the "end" 2nd level iterator for a top-level iterator | |
Helper class for NestedIterator when the 1st level iterator refers to an ordinary iterator for the 2nd level iterator.
TopLevelIterT | type of the top-level iterator to be used for NestedIterator. |
RestIterT | type of the 2nd level iter. |
This class can be used for the case where the 2nd level iterators can be obtained by using top_level_iter.begin()
etc, e.g. for std::vector<std::vector<int>
>
The default for RestIterT
is suitable for most cases, as it finds RestIterT
from the iterator traits of TopLevelIterT
.
|
inline |
function to get the first 2nd level iterator for a top-level iterator
returns (*iter).begin()