#include <rangelib/filtered_range.hpp>
R | The range class | |
P | The filter predicate | |
RC | The range category tag type |
Member Types | |
typedef R | filtered_range_type |
typedef P | filter_predicate_type |
typedef RC | range_tag_type |
typedef filtered_range< R, P, RC > | class_type |
The type of this instantiation. | |
typedef filter_iterator < iterator_base_type, filter_predicate_type > | iterator |
The mutating (non-const) iterator type. | |
typedef filter_iterator < const_iterator_base_type, filter_predicate_type > | const_iterator |
The non-mutating (const) iterator type. | |
typedef select_first_type_if < typename::stlsoft::typefixer::fixer_reference < filtered_range_type, HAS_MEMBER_REFERENCE > ::reference, typename filtered_range_type::const_reference, HAS_MEMBER_REFERENCE >::type | reference |
The mutating (non-const) reference type. | |
typedef filtered_range_type::const_reference | const_reference |
The non-mutating (const) reference type. | |
typedef filtered_range_type::value_type | value_type |
The value type. | |
Public Member Functions | |
Construction | |
filtered_range (filtered_range_type r, filter_predicate_type pr=filter_predicate_type()) | |
Constructs from a range and a predicate. | |
Notional Range methods | |
bool | is_open () const |
Indicates whether the range is open. | |
reference | current () |
Returns the current value in the range. | |
const_reference | current () const |
Returns the current value in the range. | |
class_type & | advance () |
Advances the current position in the range. | |
Iterable Range methods | |
iterator | begin () |
Returns an iterator to the current position of the range. | |
iterator | end () |
Returns an iterator to the end of the range. | |
const_iterator | begin () const |
Returns an iterator to the current position of the range. | |
const_iterator | end () const |
Returns an iterator to the end of the range. |
typedef filtered_range<R, P, RC> class_type |
typedef filter_iterator<iterator_base_type, filter_predicate_type> iterator |
The mutating (non-const) iterator type.
typedef filter_iterator<const_iterator_base_type, filter_predicate_type> const_iterator |
The non-mutating (const) iterator type.
typedef select_first_type_if< typename ::stlsoft::typefixer::fixer_reference<filtered_range_type, HAS_MEMBER_REFERENCE>::reference , typename filtered_range_type::const_reference , HAS_MEMBER_REFERENCE >::type reference |
The mutating (non-const) reference type.
typedef filtered_range_type::const_reference const_reference |
typedef filtered_range_type::value_type value_type |
The value type.
filtered_range | ( | filtered_range_type | r, | |
filter_predicate_type | pr = filter_predicate_type() | |||
) | [inline, explicit] |
Constructs from a range and a predicate.
r | The range whose values will be filtered | |
pr | The predicate which will be used to filter the values of the range r |
bool is_open | ( | ) | const [inline] |
Indicates whether the range is open.
reference current | ( | ) | [inline] |
const_reference current | ( | ) | const [inline] |
class_type& advance | ( | ) | [inline] |
iterator begin | ( | ) | [inline] |
Returns an iterator to the current position of the range.
iterator end | ( | ) | [inline] |
Returns an iterator to the end of the range.
const_iterator begin | ( | ) | const [inline] |
Returns an iterator to the current position of the range.
const_iterator end | ( | ) | const [inline] |
Returns an iterator to the end of the range.