Scroll to navigation

std::ranges::single_view< _Tp >(3cxx) std::ranges::single_view< _Tp >(3cxx)

NAME

std::ranges::single_view< _Tp > - A view that contains exactly one element.

SYNOPSIS

#include <ranges>

Inherits std::ranges::view_interface< single_view< _Tp > >.

Public Member Functions


constexpr single_view (_Tp &&__t) noexcept(is_nothrow_move_constructible_v< _Tp >)
constexpr single_view (const _Tp &__t) noexcept(is_nothrow_copy_constructible_v< _Tp >)
template<typename... _Args>
requires constructible_from<_Tp, _Args...>constexpr single_view (in_place_t, _Args &&... __args) noexcept(is_nothrow_constructible_v< _Tp, _Args... >)"
constexpr decltype(auto) back ()
constexpr decltype(auto) back () const
constexpr const _Tp * begin () const noexcept
constexpr _Tp * begin () noexcept
constexpr const _Tp * data () const noexcept
constexpr _Tp * data () noexcept
constexpr bool empty () const noexcept(noexcept(_S_empty(_M_derived())))
constexpr bool empty () const noexcept(noexcept(ranges::size(_M_derived())==0))
constexpr bool empty () noexcept(noexcept(_S_empty(_M_derived())))
constexpr bool empty () noexcept(noexcept(ranges::size(_M_derived())==0))
constexpr const _Tp * end () const noexcept
constexpr _Tp * end () noexcept
constexpr decltype(auto) front ()
constexpr decltype(auto) front () const
constexpr operator bool () const noexcept(noexcept(ranges::empty(_M_derived())))
constexpr operator bool () noexcept(noexcept(ranges::empty(_M_derived())))
constexpr decltype(auto) operator[] (range_difference_t< _Range > __n)
constexpr decltype(auto) operator[] (range_difference_t< _Range > __n) const
constexpr auto size () const noexcept(noexcept(_S_size(_M_derived())))

Static Public Member Functions


static constexpr size_t size () noexcept

Detailed Description

template<copy_constructible _Tp>

requires is_object_v<_Tp>
class std::ranges::single_view< _Tp >"A view that contains exactly one element.

Author

Generated automatically by Doxygen for libstdc++ from the source code.

libstdc++