std::ranges::split_view<V,Pattern>:: end
|
||||||||||||||||||||||
| Range primitives | |||||||
|
|||||||
| Range concepts | |||||||||||||||||||
|
|||||||||||||||||||
| Range factories | |||||||||
|
|||||||||
| Range adaptors | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
||||||||||||
| Helper items | |||||||||||||||||
|
|
||||||||||||||||
|
constexpr
auto
end
(
)
const
;
|
(C++20부터) | |
결과 서브 범위의 끝을 나타내는 iterator 또는 sentinel 를 반환합니다. 다음 코드와 동일합니다:
constexpr
auto
end
(
)
{
if
constexpr
(
ranges::
common_range
<
V
>
)
return
iterator
{
*
this,
ranges::
end
(
base_
)
,
{
}
}
;
else
return
sentinel
{
*
this
}
;
}
반환값
예제
#include <cassert> #include <ranges> #include <string_view> int main() { constexpr std::string_view keywords{"bitand bitor bool break"}; std::ranges::split_view kw{keywords, ' '}; assert(4 == std::ranges::distance(kw.begin(), kw.end())); }
참고 항목
|
시작을 가리키는 반복자를 반환합니다
(public member function) |
|
|
끝을 가리키는 반복자 또는 센티널을 반환합니다
(
std::ranges::lazy_split_view<V,Pattern>
의
public member function)
|
|
|
(C++20)
|
범위의 끝을 나타내는 센티널을 반환합니다
(customization point object) |