名前空間
変種
操作

標準ライブラリヘッダ <experimental/ranges/range>

From cppreference.com
< cpp‎ | header‎ | experimental
 
 
標準ライブラリヘッダー
 

このヘッダーは、ranges ライブラリの一部です。

目次

[編集] Range コンセプト

std::experimental::ranges 名前空間で定義されます。
型がrangeであること、すなわち begin イテレータと end 番兵を提供することを規定する
(concept) [編集]
rangeが定数時間でそのサイズを知っていることを規定する
(concept) [編集]
rangeがviewであること、すなわち定数時間でのコピー/ムーブ/代入を持つことを規定する
(concept) [編集]
rangeが同一のイテレータ型と番兵型を持つことを規定する
(concept) [編集]
InputIterator を満たすイテレータ型を持つ Range を指定します。
(concept) [編集]
OutputIterator を満たすイテレータ型を持つ Range を指定します。
(concept) [編集]
ForwardIterator を満たすイテレータ型を持つ Range を指定します。
(concept) [編集]
BidirectionalIterator を満たすイテレータ型を持つ Range を指定します。
(concept) [編集]
RandomAccessIterator を満たすイテレータ型を持つ Range を指定します。
(concept) [編集]

[編集] Range アクセス

std::experimental::ranges 名前空間で定義されます。
rangeの先頭を指すイテレータを返す
(customization point object)[編集]
Range の終端へのイテレータを返します。
(customization point object)[編集]
rangeへの逆イテレータを返す
(customization point object)[編集]
rangeへの逆終端イテレータを返す
(customization point object)[編集]

[編集] Range プリミティブ

std::experimental::ranges 名前空間で定義されます。
定数時間で計算可能なサイズを持つ範囲のサイズを取得します。
(customization point object)[編集]
rangeが空かどうかをチェックする
(customization point object)[編集]
連続rangeの先頭へのポインタを取得する
(customization point object)[編集]
Range のイテレータ型とセンチネル型を取得します。
(alias template)[編集]

[編集] シノプシス

#include <experimental/ranges/iterator>
 
namespace std { namespace experimental { namespace ranges { inline namespace v1 {
 
namespace {
  constexpr /* unspecified */ begin = /* unspecified */;
  constexpr /* unspecified */ end = /* unspecified */;
  constexpr /* unspecified */ cbegin = /* unspecified */;
  constexpr /* unspecified */ cend = /* unspecified */;
  constexpr /* unspecified */ rbegin = /* unspecified */;
  constexpr /* unspecified */ rend = /* unspecified */;
  constexpr /* unspecified */ crbegin = /* unspecified */;
  constexpr /* unspecified */ crend = /* unspecified */;
}
 
namespace {
  constexpr /* unspecified */ size = /* unspecified */;
  constexpr /* unspecified */ empty = /* unspecified */;
  constexpr /* unspecified */ data = /* unspecified */;
  constexpr /* unspecified */ cdata = /* unspecified */;
}
 
template <class T>
using iterator_t = decltype(ranges::begin(declval<T&>()));
 
template <class T>
using sentinel_t = decltype(ranges::end(declval<T&>()));
 
template <class>
constexpr bool disable_sized_range = false;
 
template <class T>
struct enable_view { };
 
struct view_base { };
 
template <class T>
concept bool Range = /* see definition */;
 
template <class T>
concept bool SizedRange = /* see definition */;
 
template <class T>
concept bool View = /* see definition */;
 
template <class T>
concept bool BoundedRange = /* see definition */;
 
template <class T>
concept bool InputRange = /* see definition */;
 
template <class R, class T>
concept bool OutputRange = /* see definition */;
 
template <class T>
concept bool ForwardRange = /* see definition */;
 
template <class T>
concept bool BidirectionalRange = /* see definition */;
 
template <class T>
concept bool RandomAccessRange = /* see definition */;
 
}}}}
English 日本語 中文(简体) 中文(繁體)