std::ranges::view_interface<D>::cbegin
來自 cppreference.com
< cpp | ranges | view interface
constexpr auto cbegin(); |
(1) | (C++23 起) |
constexpr auto cbegin() const requires ranges::range<const D>; |
(2) | (C++23 起) |
cbegin()
成員函式的預設實現返回範圍的常量起始迭代器。
1) 令 derived 為繫結到 static_cast<D&>(*this) 的引用。
等價於 return ranges::cbegin(derived);。
2) 同 (1),除了 derived 是 static_cast<const D&>(*this)。
目錄 |
[編輯] 引數
(無)
[編輯] 返回值
範圍的常量起始迭代器。
[編輯] 注意
標準庫中的所有範圍介面卡和範圍工廠以及 std::ranges::subrange 都使用 cbegin
的預設實現。
[編輯] 示例
本節不完整 原因:無示例 |
[編輯] 參閱
(C++11)(C++14) |
返回指向容器或陣列開頭的迭代器 (函式模板) |
(C++20) |
返回只讀範圍的起始迭代器 (定製點物件) |