- Main Page
- Related Pages
- Modules
- Namespaces
- Data Structures
- Files
- Examples

- Data Structures
- Data Structure Index
- Class Hierarchy
- Data Fields

Public Types | Public Member Functions | Protected Attributes
efl::eina::_const_range_template< T, Traits > Struct Template Reference
Eina C++Eina C++ » | Data Types » Content Access » Range Eina C++Eina C++ » | Data Types » | Content Access

Range implementation for immutable collections. More...

## Public Types
typedef Traits::template const_iterator< T >::type | const_iterator
| Type for constant iterator to the range. More...
typedef Traits::template iterator< T >::type | iterator
| Type for iterator to the range. More...
typedef T | value_type
| The type of each element. More...
typedef T & | reference
| Type for a reference to an element. More...
typedef T const & | const_reference
| Type for a constant reference to an element. More...
typedef T * | pointer
| Type for a pointer to an element. More...
typedef T const * | const_pointer
| Type for a constant pointer to an element. More...
typedef std::reverse_iterator < iterator > | reverse_iterator
| Type for reverse iterator to the range. More...
typedef std::reverse_iterator < const_iterator > | const_reverse_iterator
| Type for constant reverse iterator to the range. More...
typedef std::size_t | size_type
| Type for size information. More...
typedef std::ptrdiff_t | difference_type
| Type to represent the distance between two iterators. More...
typedef Traits::template const_native_handle< T >::type | native_handle_type
| Type for the native handle of the container. More...
typedef _const_range_template < T, Traits > | _self_type
| Type of the range itself. More...

## Public Member Functions
| _const_range_template (native_handle_type handle)
| Creates a range object wrapping the given native container handle.
native_handle_type | native_handle () const
| Get a constant handle for the native Eina container. More...
value_type const & | back () const
| Get a constant reference to the last element. More...
value_type const & | front () const
| Get a constant reference to the first element. More...
const_iterator | begin () const
| Get a constant iterator pointing to the first element of the range. More...
const_iterator | end () const
| Get a constant iterator to the position following the last element of the range. More...
const_reverse_iterator | crbegin () const
| Get a constant reverse iterator pointing to the reverse begin of the range. More...
const_reverse_iterator | crend () const
| Get a constant reverse iterator pointing to the reverse end of the range. More...
const_iterator | cbegin () const
| Get a constant iterator pointing to the first element of the range. More...
const_iterator | cend () const
| Get a constant iterator to the position following the last element of the range. More...
const_reverse_iterator | rbegin ()
| Get a constant reverse iterator pointing to the reverse begin of the range. More...
const_reverse_iterator | rend ()
| Get a constant reverse iterator pointing to the reverse end of the range. More...
bool | empty () const
| Check if the range does not contain any elements. More...
size_type | size () const
| Get the number of elements in the range. More...
void | swap (_self_type &other)
| Swap content with another range of the same type. More...

## Protected Attributes
native_handle_type | _handle

## Detailed Description

### template<typename T, typename Traits>
struct efl::eina::_const_range_template< T, Traits >

Range implementation for immutable collections.

## Member Typedef Documentation

template<typename T, typename Traits>

typedef Traits::template const_iterator<T>::type efl::eina::_const_range_template< T, Traits >::const_iterator

Type for constant iterator to the range.

template<typename T, typename Traits>

typedef Traits::template iterator<T>::type efl::eina::_const_range_template< T, Traits >::iterator

Type for iterator to the range.

template<typename T, typename Traits>

typedef T efl::eina::_const_range_template< T, Traits >::value_type

The type of each element.

template<typename T, typename Traits>

typedef T& efl::eina::_const_range_template< T, Traits >::reference

Type for a reference to an element.

template<typename T, typename Traits>

typedef T const& efl::eina::_const_range_template< T, Traits >::const_reference

Type for a constant reference to an element.

template<typename T, typename Traits>

typedef T* efl::eina::_const_range_template< T, Traits >::pointer

Type for a pointer to an element.

template<typename T, typename Traits>

typedef T const* efl::eina::_const_range_template< T, Traits >::const_pointer

Type for a constant pointer to an element.

template<typename T, typename Traits>

typedef std::reverse_iterator<iterator> efl::eina::_const_range_template< T, Traits >::reverse_iterator

Type for reverse iterator to the range.

template<typename T, typename Traits>

typedef std::reverse_iterator<const_iterator> efl::eina::_const_range_template< T, Traits >::const_reverse_iterator

Type for constant reverse iterator to the range.

template<typename T, typename Traits>

typedef std::size_t efl::eina::_const_range_template< T, Traits >::size_type

Type for size information.

template<typename T, typename Traits>

typedef std::ptrdiff_t efl::eina::_const_range_template< T, Traits >::difference_type

Type to represent the distance between two iterators.

template<typename T, typename Traits>

typedef Traits::template const_native_handle<T>::type efl::eina::_const_range_template< T, Traits >::native_handle_type

Type for the native handle of the container.

template<typename T, typename Traits>

typedef _const_range_template<T, Traits> efl::eina::_const_range_template< T, Traits >::_self_type

Type of the range itself.

## Member Function Documentation

template<typename T, typename Traits>

native_handle_type efl::eina::_const_range_template< T, Traits >::native_handle | ( |  | ) | const
| inline

Get a constant handle for the native Eina container.

Returns
  Constant handle for the native Eina container.

Referenced by efl::eina::_mutable_range_template< T, Traits >::native_handle().

template<typename T, typename Traits>

value_type const& efl::eina::_const_range_template< T, Traits >::back | ( |  | ) | const
| inline

Get a constant reference to the last element.

Returns
  Constant reference to the last element of the range.

template<typename T, typename Traits>

value_type const& efl::eina::_const_range_template< T, Traits >::front | ( |  | ) | const
| inline

Get a constant reference to the first element.

Returns
  Constant reference to the first element of the range.

template<typename T, typename Traits>

const_iterator efl::eina::_const_range_template< T, Traits >::begin | ( |  | ) | const
| inline

Get a constant iterator pointing to the first element of the range.

Returns
  Constant iterator to the initial position of the range.

This member function returns a constant iterator pointing to the first element of the range. If the range contains no elements the returned iterator is the same as the one returned by end() const.

References efl::eina::_const_range_template< T, Traits >::cbegin().

template<typename T, typename Traits>

const_iterator efl::eina::_const_range_template< T, Traits >::end | ( |  | ) | const
| inline

Get a constant iterator to the position following the last element of the range.

Returns
  Constant iterator to the final position of the range.

This member function returns a constant iterator to the position following the last element in the range. If the range contains no elements the returned iterator is the same as the one returned by begin() const.

Note
  Note that attempting to access this position causes undefined behavior.

References efl::eina::_const_range_template< T, Traits >::cend().

template<typename T, typename Traits>

const_reverse_iterator efl::eina::_const_range_template< T, Traits >::crbegin | ( |  | ) | const
| inline

Get a constant reverse iterator pointing to the reverse begin of the range.

Returns
  Constant reverse iterator pointing to the reverse begin of the range.

This member function works like but is granted to return a constant reverse iterator even for a range to a mutable collection.

Referenced by efl::eina::_const_range_template< T, Traits >::rbegin().

template<typename T, typename Traits>

const_reverse_iterator efl::eina::_const_range_template< T, Traits >::crend | ( |  | ) | const
| inline

Get a constant reverse iterator pointing to the reverse end of the range.

Returns
  Constant reverse iterator pointing to the reverse end of the range.

This member function works like but is granted to return a constant reverse iterator even for range to a mutable collection.

Referenced by efl::eina::_const_range_template< T, Traits >::rend().

template<typename T, typename Traits>

const_iterator efl::eina::_const_range_template< T, Traits >::cbegin | ( |  | ) | const
| inline

Get a constant iterator pointing to the first element of the range.

Returns
  Constant iterator to the initial position of the range.

This member function works like but is granted to return a constant iterator even for a range to a mutable collection.

Referenced by efl::eina::_const_range_template< T, Traits >::begin().

template<typename T, typename Traits>

const_iterator efl::eina::_const_range_template< T, Traits >::cend | ( |  | ) | const
| inline

Get a constant iterator to the position following the last element of the range.

Returns
  Constant iterator to the final position of the range.

This member function works like end() const but is granted to return a constant iterator even for a range to a mutable collection.

Referenced by efl::eina::_const_range_template< T, Traits >::end().

template<typename T, typename Traits>

const_reverse_iterator efl::eina::_const_range_template< T, Traits >::rbegin | ( |  | ) |
| inline

Get a constant reverse iterator pointing to the reverse begin of the range.

Returns
  Constant reverse iterator pointing to the reverse begin of the range.

This member function returns a constant reverse iterator pointing to the last element of the range. If the range is empty the returned reverse iterator is the same as the one returned by rend().

References efl::eina::_const_range_template< T, Traits >::crbegin().

template<typename T, typename Traits>

const_reverse_iterator efl::eina::_const_range_template< T, Traits >::rend | ( |  | ) |
| inline

Get a constant reverse iterator pointing to the reverse end of the range.

Returns
  Constant reverse iterator pointing to the reverse end of the range.

This member function returns a constant reverse iterator pointing to the position before the first element of the range. If the range is empty the returned iterator is the same as the one returned by rbegin().

Note
  Note that attempting to access this position causes undefined behavior.

References efl::eina::_const_range_template< T, Traits >::crend().

template<typename T, typename Traits>

bool efl::eina::_const_range_template< T, Traits >::empty | ( |  | ) | const
| inline

Check if the range does not contain any elements.

Returns
  `true` if there is no elements in the range, `false` otherwise.

This member function returns `true` if the range does not contain any elements, otherwise it returns `false`.

template<typename T, typename Traits>

size_type efl::eina::_const_range_template< T, Traits >::size | ( |  | ) | const
| inline

Get the number of elements in the range.

Returns
  Number of elements in the range.

This member function returns the current number of elements in the range.

template<typename T, typename Traits>

void efl::eina::_const_range_template< T, Traits >::swap | ( | _self_type & | other | ) |
| inline

Swap content with another range of the same type.

Parameters

  other | Another range of the same type.

References efl::eina::swap().

Referenced by efl::eina::swap().