Vcsn  2.4
Be Rational
vcsn::container_filter_range< Cont, Pred > Struct Template Reference

#include <fwd.hh>

Collaboration diagram for vcsn::container_filter_range< Cont, Pred >:

Public Types

using container_t = Cont
 
using unref_C = typename std::remove_reference< container_t >::type
 
using value_type = typename unref_C::value_type
 
using predicate_t = Pred
 
using const_iterator = boost::filter_iterator< predicate_t, typename unref_C::const_iterator >
 

Public Member Functions

 container_filter_range (const unref_C &cont, predicate_t predicate)
 
const_iterator begin () const
 
const_iterator end () const
 
value_type front () const
 The first element. More...
 
value_type back () const
 The last element. More...
 
ATTRIBUTE_PURE bool empty () const
 
ATTRIBUTE_PURE size_t size () const
 

Private Attributes

const container_t cont_
 
predicate_t predicate_
 

Detailed Description

template<typename Cont, typename Pred>
struct vcsn::container_filter_range< Cont, Pred >

Definition at line 14 of file fwd.hh.

Member Typedef Documentation

template<typename Cont , typename Pred >
using vcsn::container_filter_range< Cont, Pred >::const_iterator = boost::filter_iterator<predicate_t, typename unref_C::const_iterator>

Definition at line 58 of file crange.hh.

template<typename Cont , typename Pred >
using vcsn::container_filter_range< Cont, Pred >::container_t = Cont

Definition at line 53 of file crange.hh.

template<typename Cont , typename Pred >
using vcsn::container_filter_range< Cont, Pred >::predicate_t = Pred

Definition at line 56 of file crange.hh.

template<typename Cont , typename Pred >
using vcsn::container_filter_range< Cont, Pred >::unref_C = typename std::remove_reference<container_t>::type

Definition at line 54 of file crange.hh.

template<typename Cont , typename Pred >
using vcsn::container_filter_range< Cont, Pred >::value_type = typename unref_C::value_type

Definition at line 55 of file crange.hh.

Constructor & Destructor Documentation

template<typename Cont , typename Pred >
vcsn::container_filter_range< Cont, Pred >::container_filter_range ( const unref_C cont,
predicate_t  predicate 
)
inline

Definition at line 60 of file crange.hh.

Member Function Documentation

template<typename Cont , typename Pred >
value_type vcsn::container_filter_range< Cont, Pred >::back ( ) const
inline

The last element.

Precondition
!empty().
Note
: we don't return by reference, as begin returns a temporary.

Definition at line 89 of file crange.hh.

References vcsn::container_filter_range< Cont, Pred >::cont_, and vcsn::container_filter_range< Cont, Pred >::empty().

Here is the call graph for this function:

template<typename Cont , typename Pred >
ATTRIBUTE_PURE bool vcsn::container_filter_range< Cont, Pred >::empty ( ) const
inline

Definition at line 96 of file crange.hh.

References vcsn::container_filter_range< Cont, Pred >::begin(), and vcsn::container_filter_range< Cont, Pred >::end().

Referenced by vcsn::container_filter_range< Cont, Pred >::back(), and vcsn::container_filter_range< Cont, Pred >::front().

Here is the call graph for this function:

template<typename Cont , typename Pred >
value_type vcsn::container_filter_range< Cont, Pred >::front ( ) const
inline

The first element.

Precondition
!empty().
Note
: we don't return by reference, as begin returns a temporary.

Definition at line 79 of file crange.hh.

References vcsn::container_filter_range< Cont, Pred >::begin(), and vcsn::container_filter_range< Cont, Pred >::empty().

Here is the call graph for this function:

template<typename Cont , typename Pred >
ATTRIBUTE_PURE size_t vcsn::container_filter_range< Cont, Pred >::size ( ) const
inline

Definition at line 102 of file crange.hh.

References vcsn::container_filter_range< Cont, Pred >::begin(), and vcsn::container_filter_range< Cont, Pred >::end().

Here is the call graph for this function:

Member Data Documentation

template<typename Cont , typename Pred >
predicate_t vcsn::container_filter_range< Cont, Pred >::predicate_
private

The documentation for this struct was generated from the following files: