std::basic_string_view::
swap
From cppreference.com
<
cpp
|
string
|
basic string view
C++
Language
Standard library headers
Concepts
Utilities library
Strings library
Containers library
Algorithms library
Iterators library
Numerics library
Input/output library
Localizations library
Regular expressions library
(C++11)
Atomic operations library
(C++11)
Thread support library
(C++11)
Filesystem library
(C++17)
Technical Specifications
Strings library
Null-terminated strings
Byte strings
Multibyte strings
Wide strings
Classes
basic_string
basic_string_view
(C++17)
char_traits
std::basic_string_view
Member functions
basic_string_view::basic_string_view
basic_string_view::operator=
Iterators
basic_string_view::begin
basic_string_view::cbegin
basic_string_view::end
basic_string_view::cend
basic_string_view::rbegin
basic_string_view::crbegin
basic_string_view::rend
basic_string_view::crend
Element access
basic_string_view::at
basic_string_view::operator[]
basic_string_view::front
basic_string_view::back
basic_string_view::data
Capacity
basic_string_view::size
basic_string_view::length
basic_string_view::max_size
basic_string_view::empty
Modifers
basic_string_view::remove_prefix
basic_string_view::remove_suffix
basic_string_view::swap
Operations
basic_string_view::to_string
basic_string_view::operator basic_string
basic_string_view::copy
basic_string_view::substr
basic_string_view::compare
basic_string_view::find
basic_string_view::rfind
basic_string_view::find_first_of
basic_string_view::find_last_of
basic_string_view::find_first_not_of
basic_string_view::find_last_not_of
Constants
basic_string_view::npos
Non-member functions
operator==
operator!=
operator<
operator>
operator<=
operator>=
operator<<
Helper classes
hash
<std::string_view>
hash
<std::wstring_view>
hash
<std::u16string_view>
hash
<std::u32string_view>
constexpr
void
swap
(
basic_string_view
&
v
)
;
(since C++17)
Exchanges the view with that of
v
.
Contents
1
Parameters
2
Return value
3
Exceptions
4
Complexity
[
edit
]
Parameters
v
-
view to swap with
[
edit
]
Return value
(none)
[
edit
]
Exceptions
noexcept
specification:
noexcept
[
edit
]
Complexity
Constant.
Category
:
unconditionally noexcept