4.6.0
Freundlich's C++ toolkit
Loading...
Searching...
No Matches
fcppt::int_range< Int > Class Template Reference

Detailed Description

template<typename Int>
class fcppt::int_range< Int >

A forward range over integers.

Public Types

using value_type = Int
 
using iterator = fcppt::int_iterator<Int>
 
using const_iterator = iterator
 
using size_type = fcppt::type_iso::undecorated_type<Int>
 

Public Member Functions

constexpr int_range (Int begin, Int end)
 Creates a range.
 
constexpr iterator begin () const
 
constexpr iterator end () const
 
constexpr size_type size () const
 

Member Typedef Documentation

◆ const_iterator

template<typename Int >
using fcppt::int_range< Int >::const_iterator = iterator

◆ iterator

template<typename Int >
using fcppt::int_range< Int >::iterator = fcppt::int_iterator<Int>

◆ size_type

template<typename Int >
using fcppt::int_range< Int >::size_type = fcppt::type_iso::undecorated_type<Int>

◆ value_type

template<typename Int >
using fcppt::int_range< Int >::value_type = Int

Constructor & Destructor Documentation

◆ int_range()

template<typename Int >
fcppt::int_range< Int >::int_range ( Int begin,
Int end )
constexpr

Creates a range.

If end < begin the range will be empty.

Parameters
beginThe first element in the range
endThe element one past the end

Member Function Documentation

◆ begin()

template<typename Int >
iterator fcppt::int_range< Int >::begin ( ) const
nodiscardconstexpr

◆ end()

template<typename Int >
iterator fcppt::int_range< Int >::end ( ) const
nodiscardconstexpr

◆ size()

template<typename Int >
size_type fcppt::int_range< Int >::size ( ) const
nodiscardconstexpr