tetl 0.1.0
Embedded Template Library
Loading...
Searching...
No Matches
basic_inplace_string< Char, Capacity, Traits > Struct Template Reference

basic_inplace_string class with fixed size capacity. More...

#include <etl/string.hpp>

Public Types

using const_iterator = Char const*
 
using const_pointer = Char const*
 
using const_reference = Char const&
 
using const_reverse_iterator = etl::reverse_iterator<const_iterator>
 
using difference_type = etl::ptrdiff_t
 
using iterator = Char*
 
using pointer = Char*
 
using reference = Char&
 
using reverse_iterator = etl::reverse_iterator<iterator>
 
using size_type = etl::size_t
 
using traits_type = Traits
 
using value_type = Char
 

Public Member Functions

constexpr basic_inplace_string ()=default
 Default constructor.
 
constexpr basic_inplace_string (basic_inplace_string &&) noexcept=default
 Defaulted move constructor.
 
constexpr basic_inplace_string (basic_inplace_string const &) noexcept=default
 Defaulted copy constructor.
 
constexpr basic_inplace_string (basic_inplace_string const &other, size_type pos)
 Constructs the string with a substring [pos, other.size()).
 
constexpr basic_inplace_string (basic_inplace_string const &other, size_type pos, size_type count)
 Constructs the string with a substring [pos, pos+count) of other.
 
constexpr basic_inplace_string (const_pointer str) noexcept
 Character pointer constructor. Calls traits_type::length.
 
constexpr basic_inplace_string (const_pointer str, size_type const len) noexcept
 Character pointer constructor.
 
template<typename InputIt>
requires (detail::InputIterator<InputIt>)
constexpr basic_inplace_string (InputIt first, InputIt last) noexcept
 Constructs the string with the contents of the range [ first, last). Fails silently if input length is greater then capacity.
 
constexpr basic_inplace_string (nullptr_t)=delete
 
constexpr basic_inplace_string (size_type count, Char ch) noexcept
 Constructs the string with count copies of character ch.
 
template<typename StringView>
requires string_view_like<StringView>
constexpr basic_inplace_string (StringView const &view) noexcept
 Implicitly converts view to a string view sv, then initializes the string with the contents of sv.
 
template<typename StringView>
requires string_view_like<StringView>
constexpr basic_inplace_string (StringView const &view, size_type pos, size_type n)
 Implicitly converts view to a string view sv, then initializes the string with the subrange [ pos, pos + n ) of sv.
 
constexpr auto append (basic_inplace_string const &str) noexcept -> basic_inplace_string &
 Appends string str.
 
constexpr auto append (basic_inplace_string const &str, size_type pos, size_type count=npos) noexcept -> basic_inplace_string &
 Appends a substring [ pos, pos + count ) of str.
 
constexpr auto append (const_pointer s) noexcept -> basic_inplace_string &
 Appends the null-terminated character string pointed to by s. The length of the string is determined by the first null character using.
 
constexpr auto append (const_pointer str, size_type count) noexcept -> basic_inplace_string &
 Appends characters in the range [ str, str + count ). This range can contain null characters.
 
template<typename InputIt>
requires (detail::InputIterator<InputIt>)
constexpr auto append (InputIt first, InputIt last) noexcept -> basic_inplace_string &
 Appends characters in the range [ first , last ).
 
constexpr auto append (size_type const count, Char const s) noexcept -> basic_inplace_string &
 Appends count copies of character s.
 
template<typename StringView>
requires string_view_like<StringView>
constexpr auto append (StringView const &view) -> basic_inplace_string &
 Implicitly converts view to a string_view sv, then appends all characters from sv.
 
template<typename StringView>
requires string_view_like<StringView>
constexpr auto append (StringView const &view, size_type pos, size_type count=npos) -> basic_inplace_string &
 Implicitly converts view to a string_view sv then appends the characters from the subview [ pos, pos + count ) of sv.
 
constexpr auto assign (basic_inplace_string const &str) noexcept -> basic_inplace_string &
 Replaces the contents with a copy of str.
 
constexpr auto assign (basic_inplace_string const &str, size_type pos, size_type count=npos) noexcept -> basic_inplace_string &
 Replaces the contents with a substring [ pos, pos + count ) of str.
 
constexpr auto assign (const_pointer s) noexcept -> basic_inplace_string &
 Replaces the contents with those of null-terminated character string pointed to by s.
 
constexpr auto assign (const_pointer s, size_type count) noexcept -> basic_inplace_string &
 Replaces the contents with copies of the characters in the range [ s, s + count ). This range can contain null characters.
 
template<typename InputIt>
requires (detail::InputIterator<InputIt>)
constexpr auto assign (InputIt first, InputIt last) noexcept -> basic_inplace_string &
 Replaces the contents with copies of the characters in the range [ first , last ).
 
constexpr auto assign (size_type count, Char ch) noexcept -> basic_inplace_string &
 Replaces the contents with count copies of character ch.
 
template<typename StringView>
requires string_view_like<StringView>
constexpr auto assign (StringView const &view) noexcept -> basic_inplace_string &
 Implicitly converts view to a string view sv, then replaces the contents with the characters from sv.
 
template<typename StringView>
requires string_view_like<StringView>
constexpr auto assign (StringView const &view, size_type pos, size_type count=npos) noexcept -> basic_inplace_string &
 Implicitly converts view to a string view sv, then replaces the contents with the characters from the subview [ pos, pos + count ) of sv.
 
constexpr auto back () const noexcept -> const_reference
 Accesses the last character.
 
constexpr auto back () noexcept -> reference
 Accesses the last character.
 
constexpr auto begin () const noexcept -> const_iterator
 Returns an const iterator to the beginning.
 
constexpr auto begin () noexcept -> iterator
 Returns an iterator to the beginning.
 
constexpr auto c_str () const noexcept -> const_pointer
 Returns a pointer to a null-terminated character array.
 
constexpr auto capacity () const noexcept -> size_type
 Returns the number of characters that can be held in allocated storage, NOT including the null terminator.
 
constexpr auto cbegin () const noexcept -> const_iterator
 Returns an const iterator to the beginning.
 
constexpr auto cend () const noexcept -> const_iterator
 Returns an const iterator to the end.
 
constexpr auto clear () noexcept -> void
 Removes all characters from the string. Sets size to 0 and overrides the buffer with zeros.
 
constexpr auto compare (basic_inplace_string const &str) const noexcept -> int
 Compares this string to str.
 
template<size_type OtherCapacity>
constexpr auto compare (basic_inplace_string< Char, OtherCapacity, traits_type > const &str) const noexcept -> int
 Compares this string to str with other capacity.
 
constexpr auto compare (const_pointer s) const -> int
 Compares this string to the null-terminated character sequence beginning at the character pointed to by s with length traits_type::length(s).
 
constexpr auto compare (size_type const pos, size_type const count, basic_inplace_string const &str) const -> int
 Compares a [pos, pos+count) substring of this string to str. If count > size() - pos the substring is [pos, size()).
 
constexpr auto compare (size_type const pos, size_type const count, const_pointer s) const -> int
 Compares a [pos1, pos1+count1) substring of this string to the null-terminated character sequence beginning at the character pointed to by s with length traits_type::length(s). If count1 > size() - pos1 the substring is [pos1, size()).
 
constexpr auto compare (size_type const pos1, size_type const count1, basic_inplace_string const &str, size_type const pos2, size_type const count2=npos) const -> int
 Compares a [pos1, pos1+count1) substring of this string to a substring [pos2, pos2+count2) of str. If count1 > size() - pos1 the first substring is [pos1, size()). Likewise, count2 > str.size() - pos2 the second substring is [pos2, str.size()).
 
constexpr auto compare (size_type const pos1, size_type const count1, const_pointer s, size_type const count2) const -> int
 Compares a [pos1, pos1+count1) substring of this string to the characters in the range [s, s + count2). If count1 > size() - pos1 the substring is [pos1, size()). (Note: the characters in the range [s, s + count2) may include null characters.)
 
template<typename StringView>
requires string_view_like<StringView>
constexpr auto compare (size_type pos1, size_type count1, StringView const &view) const noexcept -> int
 Implicitly converts view to a string view sv, then compares a [pos1, pos1+count1) substring of this string to sv.
 
template<typename StringView>
requires string_view_like<StringView>
constexpr auto compare (size_type pos1, size_type count1, StringView const &view, size_type pos2, size_type count2=npos) const noexcept -> int
 Implicitly converts view to a string view sv, then compares a [pos1, pos1+count1) substring of this string to a substring [pos2, pos2+count2) of sv.
 
template<typename StringView>
requires string_view_like<StringView>
constexpr auto compare (StringView const &view) const noexcept -> int
 Implicitly converts view to a string view sv, then compares the content of this string to sv.
 
constexpr auto contains (Char c) const noexcept -> bool
 Checks if the string contains the given substring.
 
constexpr auto contains (Char const *s) const -> bool
 Checks if the string contains the given substring.
 
constexpr auto contains (etl::basic_string_view< Char, Traits > sv) const noexcept -> bool
 Checks if the string contains the given substring.
 
constexpr auto copy (pointer destination, size_type count, size_type pos=0) const -> size_type
 Copies a substring [pos, pos+count) to character string pointed to by dest. If the requested substring lasts past the end of the string, or if count == npos, the copied substring is [pos, size()). The resulting character string is not null-terminated.
 
constexpr auto crbegin () const noexcept -> const_reverse_iterator
 Returns a reverse iterator to the first character of the reversed string. It corresponds to the last character of the non-reversed string.
 
constexpr auto crend () const noexcept -> const_reverse_iterator
 Returns a reverse iterator to the first character of the reversed string. It corresponds to the last character of the non-reversed string.
 
constexpr auto data () const noexcept -> const_pointer
 Returns a pointer to the underlying array serving as character storage. The pointer is such that the range [data(); data() + size()) is valid and the values in it correspond to the values stored in the string.
 
constexpr auto data () noexcept -> pointer
 Returns a pointer to the underlying array serving as character storage. The pointer is such that the range [data(); data() + size()) is valid and the values in it correspond to the values stored in the string.
 
constexpr auto empty () const noexcept -> bool
 Checks whether the string is empty.
 
constexpr auto end () const noexcept -> const_iterator
 Returns an const iterator to the end.
 
constexpr auto end () noexcept -> iterator
 Returns an iterator to the end.
 
constexpr auto ends_with (basic_string_view< Char, Traits > sv) const noexcept -> bool
 Checks if the string ends with the given prefix.
 
constexpr auto ends_with (Char c) const noexcept -> bool
 Checks if the string ends with the given prefix.
 
constexpr auto ends_with (const_pointer str) const -> bool
 Checks if the string ends with the given prefix.
 
constexpr auto erase (const_iterator first, const_iterator last) noexcept -> iterator
 Removes the characters in the range [first, last).
 
constexpr auto erase (const_iterator position) noexcept -> iterator
 Removes the character at position.
 
constexpr auto erase (size_type index=0, size_type count=npos) noexcept -> basic_inplace_string &
 Removes min(count, size() - index) characters starting at index.
 
constexpr auto find (basic_inplace_string const &str, size_type pos=0) const noexcept -> size_type
 Finds the first substring equal to the given character sequence. Search begins at pos, i.e. the found substring must not begin in a position preceding pos.
 
constexpr auto find (Char ch, size_type pos=0) const noexcept -> size_type
 Finds the first substring equal to the given character sequence. Search begins at pos, i.e. the found substring must not begin in a position preceding pos.
 
constexpr auto find (const_pointer s, size_type pos, size_type count) const noexcept -> size_type
 Finds the first substring equal to the given character sequence. Search begins at pos, i.e. the found substring must not begin in a position preceding pos.
 
constexpr auto find (const_pointer s, size_type pos=0) const noexcept -> size_type
 Finds the first substring equal to the given character sequence. Search begins at pos, i.e. the found substring must not begin in a position preceding pos.
 
constexpr auto find_first_not_of (basic_inplace_string const &str, size_type pos=0) const noexcept -> size_type
 Finds the first character not equal to any of the characters in the given character sequence.
 
constexpr auto find_first_not_of (Char ch, size_type pos=0) const noexcept -> size_type
 Finds the first character not equal to any of the characters in the given character sequence.
 
constexpr auto find_first_not_of (Char const *s, size_type pos) const -> size_type
 Finds the first character not equal to any of the characters in the given character sequence.
 
constexpr auto find_first_not_of (Char const *s, size_type pos, size_type count) const -> size_type
 Finds the first character not equal to any of the characters in the given character sequence.
 
constexpr auto find_first_of (basic_inplace_string const &str, size_type pos=0) const noexcept -> size_type
 Finds the first character equal to one of the characters in the given character sequence. The search considers only the interval [pos, size()). If the character is not present in the interval, npos will be returned.
 
constexpr auto find_first_of (basic_string_view< Char, traits_type > str, size_type pos=0) const noexcept -> size_type
 Finds the first character equal to one of the characters in the given character sequence. The search considers only the interval [pos, size()). If the character is not present in the interval, npos will be returned.
 
constexpr auto find_first_of (Char ch, size_type pos=0) const noexcept -> size_type
 Finds the first character equal to one of the characters in the given character sequence. The search considers only the interval [pos, size()). If the character is not present in the interval, npos will be returned.
 
constexpr auto find_first_of (const_pointer s, size_type pos, size_type count) const -> size_type
 Finds the first character equal to one of the characters in the given character sequence. The search considers only the interval [pos, size()). If the character is not present in the interval, npos will be returned.
 
constexpr auto find_first_of (const_pointer s, size_type pos=0) const -> size_type
 Finds the first character equal to one of the characters in the given character sequence. The search considers only the interval [pos, size()). If the character is not present in the interval, npos will be returned.
 
constexpr auto find_last_not_of (basic_inplace_string const &str, size_type pos=0) const noexcept -> size_type
 Finds the last character equal to none of the characters in the given character sequence. The search considers only the interval [0, pos]. If the character is not present in the interval, npos will be returned.
 
constexpr auto find_last_not_of (Char c, size_type pos=0) const noexcept -> size_type
 Finds the last character equal to none of the characters in the given character sequence. The search considers only the interval [0, pos]. If the character is not present in the interval, npos will be returned.
 
constexpr auto find_last_not_of (Char const *s, size_type pos, size_type count) const -> size_type
 Finds the last character equal to none of the characters in the given character sequence. The search considers only the interval [0, pos]. If the character is not present in the interval, npos will be returned.
 
constexpr auto find_last_not_of (Char const *s, size_type pos=0) const -> size_type
 Finds the last character equal to none of the characters in the given character sequence. The search considers only the interval [0, pos]. If the character is not present in the interval, npos will be returned.
 
constexpr auto find_last_of (basic_inplace_string const &str, size_type pos=0) const noexcept -> size_type
 Finds the last character equal to one of characters in the given character sequence. The exact search algorithm is not specified. The search considers only the interval [0, pos]. If the character is not present in the interval, npos will be returned.
 
constexpr auto find_last_of (Char c, size_type pos=0) const noexcept -> size_type
 Finds the last character equal to one of characters in the given character sequence. The exact search algorithm is not specified. The search considers only the interval [0, pos]. If the character is not present in the interval, npos will be returned.
 
constexpr auto find_last_of (Char const *s, size_type pos, size_type count) const -> size_type
 Finds the last character equal to one of characters in the given character sequence. The exact search algorithm is not specified. The search considers only the interval [0, pos]. If the character is not present in the interval, npos will be returned.
 
constexpr auto find_last_of (Char const *s, size_type pos=0) const -> size_type
 Finds the last character equal to one of characters in the given character sequence. The exact search algorithm is not specified. The search considers only the interval [0, pos]. If the character is not present in the interval, npos will be returned.
 
constexpr auto front () const noexcept -> const_reference
 Accesses the first character.
 
constexpr auto front () noexcept -> reference
 Accesses the first character.
 
constexpr auto full () const noexcept -> bool
 Checks whether the string is full. i.e. size() == capacity()
 
constexpr auto insert (size_type const index, basic_inplace_string const &str) noexcept -> basic_inplace_string &
 Inserts string str at the position index.
 
constexpr auto insert (size_type const index, basic_inplace_string const &str, size_type const indexStr, size_type const count=npos) noexcept -> basic_inplace_string &
 Inserts a string, obtained by str.substr(index_str, count) at the position index.
 
constexpr auto insert (size_type const index, const_pointer s) noexcept -> basic_inplace_string &
 Inserts null-terminated character string pointed to by s at the position index.
 
constexpr auto insert (size_type const index, const_pointer s, size_type const count) noexcept -> basic_inplace_string &
 Inserts the characters in the range [s, s+count) at the position index. The range can contain null characters.
 
constexpr auto insert (size_type const index, size_type const count, Char const ch) noexcept -> basic_inplace_string &
 Inserts count copies of character ch at the position index.
 
template<typename StringView>
requires string_view_like<StringView>
constexpr auto insert (size_type const index, StringView const &view, size_type const indexStr, size_type const count=npos) noexcept -> basic_inplace_string &
 Implicitly converts view to a string view sv, then inserts, before the element (if any) pointed by pos, the characters from the subview [index_str, index_str+count) of sv.
 
template<typename StringView>
requires string_view_like<StringView>
constexpr auto insert (size_type const pos, StringView const &view) noexcept -> basic_inplace_string &
 Implicitly converts view to a string view sv, then inserts the elements from sv before the element (if any) pointed by pos.
 
constexpr auto length () const noexcept -> size_type
 Returns the number of characters.
 
constexpr auto max_size () const noexcept -> size_type
 Returns the number of characters that can be held in allocated storage, NOT including the null terminator.
 
constexpr operator basic_string_view< Char, traits_type > () const noexcept
 Returns a etl::basic_string_view.
 
constexpr auto operator+= (basic_inplace_string const &str) noexcept -> basic_inplace_string &
 Appends string str.
 
constexpr auto operator+= (Char ch) noexcept -> basic_inplace_string &
 Appends character ch.
 
constexpr auto operator+= (const_pointer s) noexcept -> basic_inplace_string &
 Appends the null-terminated character string pointed to by s.
 
template<typename StringView>
requires string_view_like<StringView>
constexpr auto operator+= (StringView const &view) noexcept -> basic_inplace_string &
 Implicitly converts view to a string view sv, then appends characters in the string view sv.
 
constexpr auto operator= (basic_inplace_string &&) noexcept -> basic_inplace_string &=default
 Defaulted move assignment.
 
constexpr auto operator= (basic_inplace_string const &) noexcept -> basic_inplace_string &=default
 Defaulted copy assignment.
 
constexpr auto operator= (Char ch) noexcept -> basic_inplace_string &
 Replaces the contents with character ch.
 
constexpr auto operator= (const_pointer s) noexcept -> basic_inplace_string &
 Replaces the contents with those of null-terminated character string pointed to by s.
 
constexpr auto operator= (nullptr_t) -> basic_inplace_string &=delete
 
template<typename StringView>
requires string_view_like<StringView>
constexpr auto operator= (StringView const &view) noexcept -> basic_inplace_string &
 Implicitly converts view to a string view sv, then replaces the contents with those of the sv.
 
constexpr auto operator[] (size_type index) const noexcept -> const_reference
 Accesses the specified character without bounds checking.
 
constexpr auto operator[] (size_type index) noexcept -> reference
 Accesses the specified character without bounds checking.
 
constexpr auto pop_back () noexcept -> void
 Removes the last character from the string.
 
constexpr auto push_back (Char ch) noexcept -> void
 Appends the given character ch to the end of the string.
 
constexpr auto rbegin () const noexcept -> const_reverse_iterator
 Returns a reverse iterator to the first character of the reversed string. It corresponds to the last character of the non-reversed string.
 
constexpr auto rbegin () noexcept -> reverse_iterator
 Returns a reverse iterator to the first character of the reversed string. It corresponds to the last character of the non-reversed string.
 
constexpr auto rend () const noexcept -> const_reverse_iterator
 Returns a reverse iterator to the first character of the reversed string. It corresponds to the last character of the non-reversed string.
 
constexpr auto rend () noexcept -> reverse_iterator
 Returns a reverse iterator to the first character of the reversed string. It corresponds to the last character of the non-reversed string.
 
constexpr auto replace (const_iterator first, const_iterator last, basic_inplace_string const &str) -> basic_inplace_string &
 Replaces the part of the string indicated [first, last) with a new string.
 
constexpr auto replace (const_iterator first, const_iterator last, Char const *str) -> basic_inplace_string &
 
constexpr auto replace (const_iterator first, const_iterator last, Char const *str, size_type count2) -> basic_inplace_string &
 
constexpr auto replace (const_iterator first, const_iterator last, size_type count2, Char ch) -> basic_inplace_string &
 
constexpr auto replace (size_type pos, size_type count, basic_inplace_string const &str) -> basic_inplace_string &
 Replaces the part of the string indicated [pos, pos + count) with a new string.
 
constexpr auto replace (size_type pos, size_type count, basic_inplace_string const &str, size_type pos2, size_type count2=npos) -> basic_inplace_string &
 
constexpr auto replace (size_type pos, size_type count, Char const *str) -> basic_inplace_string &
 
constexpr auto replace (size_type pos, size_type count, Char const *str, size_type count2) -> basic_inplace_string &
 
constexpr auto resize (size_type count) noexcept -> void
 Resizes the string to contain count characters.
 
constexpr auto resize (size_type count, Char ch) noexcept -> void
 Resizes the string to contain count characters.
 
constexpr auto rfind (basic_inplace_string const &str, size_type pos=0) const noexcept -> size_type
 Finds the last substring equal to the given character sequence. Search begins at pos, i.e. the found substring must not begin in a position following pos. If npos or any value not smaller than size()-1 is passed as pos, whole string will be searched.
 
constexpr auto rfind (Char ch, size_type pos=0) const noexcept -> size_type
 Finds the last substring equal to the given character sequence. Search begins at pos, i.e. the found substring must not begin in a position following pos. If npos or any value not smaller than size()-1 is passed as pos, whole string will be searched.
 
constexpr auto rfind (const_pointer s, size_type pos, size_type count) const noexcept -> size_type
 Finds the last substring equal to the given character sequence. Search begins at pos, i.e. the found substring must not begin in a position following pos. If npos or any value not smaller than size()-1 is passed as pos, whole string will be searched.
 
constexpr auto rfind (const_pointer s, size_type pos=0) const noexcept -> size_type
 Finds the last substring equal to the given character sequence. Search begins at pos, i.e. the found substring must not begin in a position following pos. If npos or any value not smaller than size()-1 is passed as pos, whole string will be searched.
 
constexpr auto size () const noexcept -> size_type
 Returns the number of characters.
 
constexpr auto starts_with (basic_string_view< Char, Traits > sv) const noexcept -> bool
 Checks if the string begins with the given prefix.
 
constexpr auto starts_with (Char c) const noexcept -> bool
 Checks if the string begins with the given prefix.
 
constexpr auto starts_with (const_pointer s) const -> bool
 Checks if the string begins with the given prefix.
 
constexpr auto substr (size_type pos=0, size_type count=npos) const -> basic_inplace_string
 Returns a substring [pos, pos+count). If the requested substring extends past the end of the string, or if count == npos, the returned substring is [pos, size()).
 
constexpr auto swap (basic_inplace_string &other) noexcept -> void
 Exchanges the contents of the string with those of other. All iterators and references may be invalidated.
 

Static Public Member Functions

static constexpr auto reserve (size_type) -> void
 Reserve is a nop, since the capacity is fixed.
 
static constexpr auto shrink_to_fit () -> void
 Shrink to fit is a nop, since the capacity is fixed.
 

Static Public Attributes

static constexpr size_type npos = numeric_limits<size_type>::max()
 This is a special value equal to the maximum value representable by the type size_type. The exact meaning depends on context, but it is generally used either as end of string indicator by the functions that expect a string index or as the error indicator by the functions that return a string index.
 
template<typename T>
static constexpr bool string_view_like
 

Detailed Description

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
struct etl::basic_inplace_string< Char, Capacity, Traits >

basic_inplace_string class with fixed size capacity.

Template Parameters
CharBuild in type for character size (mostly 'char')
CapacityUsable capacity for basic_inplace_string (excluding null terminator)
// SPDX-License-Identifier: BSL-1.0
#undef NDEBUG
#include <etl/string.hpp>
#include <etl/cassert.hpp>
#include <etl/cctype.hpp>
#include <stdio.h>
#include <stdlib.h>
auto main() -> int
{
// Unlike a std::string you will have to decide which maximum capacity you
// need. Apart from that it behaves almost the same as the standard version.
assert(str.empty());
static_assert(str.capacity() == 32);
// You can append/push_back characters, c-strings, string_view and other
// strings of same or different capacity.
str.append("Hello", 2);
assert(str.size() == 2);
assert(str == "He");
str.append(2, 'l');
assert(str.size() == 4);
assert(str == "Hell");
str.push_back('o');
assert(!str.empty());
assert(str.size() == 5);
assert(str == "Hello");
auto other = etl::string_view{" World"};
str.append(other, 0);
assert(!str.empty());
assert(str.size() == 11);
assert(str == "Hello World");
// You can make copies.
auto const copy = str;
// You can compare strings
assert(copy == str);
// You can apply algorithms.
auto toUpper = [](auto ch) { return static_cast<char>(etl::toupper(ch)); };
etl::transform(begin(str), end(str), begin(str), toUpper);
assert(str == "HELLO WORLD");
assert(copy != str);
// You can insert at any position
str.insert(0, 2, ' ');
assert(str == " HELLO WORLD");
str.insert(7, " foo");
assert(str == " HELLO foo WORLD");
// You can check if a inplace_string starts or ends with a substring
assert(str.starts_with(" "));
assert(str.ends_with("WORLD"));
// You can convert a inplace_string into a string_view
etl::string_view view = str;
assert(view.size() == str.size());
// TODO: find & friends
// to_string
::printf("to_string<8>(1): '%s'\n", etl::to_string<8>(1).c_str());
::printf("to_string<8>(16384): '%s'\n", etl::to_string<8>(16384).c_str());
return 0;
}
#define assert(...)
Definition cassert.hpp:19
constexpr auto transform(InputIt first, InputIt last, OutputIt dest, UnaryOp op) -> OutputIt
Applies the given function to a range and stores the result in another range, beginning at dest....
Definition transform.hpp:24
constexpr auto toupper(int ch) noexcept -> int
Converts the given character to uppercase according to the character conversion rules defined by the ...
Definition toupper.hpp:26
constexpr auto end
Definition end.hpp:56
constexpr auto begin
Definition begin.hpp:61
basic_string_view< char, etl::char_traits< char > > string_view
Typedef for common character type char
Definition basic_string_view.hpp:704
constexpr auto to_string(int value) noexcept -> etl::inplace_string< Capacity >
Converts a numeric value to etl::inplace_string.
Definition to_string.hpp:28
basic_inplace_string< char, Capacity > inplace_string
Typedef for a basic_inplace_string using 'char'.
Definition basic_inplace_string.hpp:1330
constexpr auto size() const noexcept -> size_type
Returns the number of Char elements in the view, i.e. etl::distance(begin(), end()).
Definition basic_string_view.hpp:174

Member Typedef Documentation

◆ const_iterator

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
using const_iterator = Char const*

◆ const_pointer

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
using const_pointer = Char const*

◆ const_reference

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
using const_reference = Char const&

◆ const_reverse_iterator

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
using const_reverse_iterator = etl::reverse_iterator<const_iterator>

◆ difference_type

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
using difference_type = etl::ptrdiff_t

◆ iterator

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
using iterator = Char*

◆ pointer

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
using pointer = Char*

◆ reference

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
using reference = Char&

◆ reverse_iterator

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
using reverse_iterator = etl::reverse_iterator<iterator>

◆ size_type

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
using size_type = etl::size_t

◆ traits_type

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
using traits_type = Traits

◆ value_type

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
using value_type = Char

Constructor & Destructor Documentation

◆ basic_inplace_string() [1/12]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
basic_inplace_string ( )
constexprdefault

Default constructor.

◆ basic_inplace_string() [2/12]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
basic_inplace_string ( const_pointer str,
size_type const len )
inlineconstexprnoexcept

Character pointer constructor.

Precondition
len <= Capacity

◆ basic_inplace_string() [3/12]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
basic_inplace_string ( const_pointer str)
inlineconstexprnoexcept

Character pointer constructor. Calls traits_type::length.

Precondition
Length of str must be <= Capacity

◆ basic_inplace_string() [4/12]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
basic_inplace_string ( nullptr_t )
constexprdelete

◆ basic_inplace_string() [5/12]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
basic_inplace_string ( size_type count,
Char ch )
inlineconstexprnoexcept

Constructs the string with count copies of character ch.

Precondition
count <= Capacity

◆ basic_inplace_string() [6/12]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
template<typename InputIt>
requires (detail::InputIterator<InputIt>)
basic_inplace_string ( InputIt first,
InputIt last )
inlineconstexprnoexcept

Constructs the string with the contents of the range [ first, last). Fails silently if input length is greater then capacity.

◆ basic_inplace_string() [7/12]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
basic_inplace_string ( basic_inplace_string< Char, Capacity, Traits > const & other,
size_type pos,
size_type count )
inlineconstexpr

Constructs the string with a substring [pos, pos+count) of other.

◆ basic_inplace_string() [8/12]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
basic_inplace_string ( basic_inplace_string< Char, Capacity, Traits > const & other,
size_type pos )
inlineconstexpr

Constructs the string with a substring [pos, other.size()).

◆ basic_inplace_string() [9/12]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
template<typename StringView>
requires string_view_like<StringView>
basic_inplace_string ( StringView const & view)
inlineexplicitconstexprnoexcept

Implicitly converts view to a string view sv, then initializes the string with the contents of sv.

◆ basic_inplace_string() [10/12]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
template<typename StringView>
requires string_view_like<StringView>
basic_inplace_string ( StringView const & view,
size_type pos,
size_type n )
inlineexplicitconstexpr

Implicitly converts view to a string view sv, then initializes the string with the subrange [ pos, pos + n ) of sv.

◆ basic_inplace_string() [11/12]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
basic_inplace_string ( basic_inplace_string< Char, Capacity, Traits > const & )
constexprdefaultnoexcept

Defaulted copy constructor.

◆ basic_inplace_string() [12/12]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
basic_inplace_string ( basic_inplace_string< Char, Capacity, Traits > && )
constexprdefaultnoexcept

Defaulted move constructor.

Member Function Documentation

◆ append() [1/8]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto append ( basic_inplace_string< Char, Capacity, Traits > const & str) -> basic_inplace_string&
inlineconstexprnoexcept

Appends string str.

◆ append() [2/8]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto append ( basic_inplace_string< Char, Capacity, Traits > const & str,
size_type pos,
size_type count = npos ) -> basic_inplace_string&
inlineconstexprnoexcept

Appends a substring [ pos, pos + count ) of str.

◆ append() [3/8]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto append ( const_pointer s) -> basic_inplace_string&
inlineconstexprnoexcept

Appends the null-terminated character string pointed to by s. The length of the string is determined by the first null character using.

◆ append() [4/8]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto append ( const_pointer str,
size_type count ) -> basic_inplace_string&
inlineconstexprnoexcept

Appends characters in the range [ str, str + count ). This range can contain null characters.

◆ append() [5/8]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
template<typename InputIt>
requires (detail::InputIterator<InputIt>)
auto append ( InputIt first,
InputIt last ) -> basic_inplace_string&
inlineconstexprnoexcept

Appends characters in the range [ first , last ).

◆ append() [6/8]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto append ( size_type const count,
Char const s ) -> basic_inplace_string&
inlineconstexprnoexcept

Appends count copies of character s.

◆ append() [7/8]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
template<typename StringView>
requires string_view_like<StringView>
auto append ( StringView const & view) -> basic_inplace_string&
inlineconstexpr

Implicitly converts view to a string_view sv, then appends all characters from sv.

◆ append() [8/8]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
template<typename StringView>
requires string_view_like<StringView>
auto append ( StringView const & view,
size_type pos,
size_type count = npos ) -> basic_inplace_string&
inlineconstexpr

Implicitly converts view to a string_view sv then appends the characters from the subview [ pos, pos + count ) of sv.

◆ assign() [1/8]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto assign ( basic_inplace_string< Char, Capacity, Traits > const & str) -> basic_inplace_string&
inlineconstexprnoexcept

Replaces the contents with a copy of str.

◆ assign() [2/8]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto assign ( basic_inplace_string< Char, Capacity, Traits > const & str,
size_type pos,
size_type count = npos ) -> basic_inplace_string&
inlineconstexprnoexcept

Replaces the contents with a substring [ pos, pos + count ) of str.

◆ assign() [3/8]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto assign ( const_pointer s) -> basic_inplace_string&
inlineconstexprnoexcept

Replaces the contents with those of null-terminated character string pointed to by s.

◆ assign() [4/8]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto assign ( const_pointer s,
size_type count ) -> basic_inplace_string&
inlineconstexprnoexcept

Replaces the contents with copies of the characters in the range [ s, s + count ). This range can contain null characters.

◆ assign() [5/8]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
template<typename InputIt>
requires (detail::InputIterator<InputIt>)
auto assign ( InputIt first,
InputIt last ) -> basic_inplace_string&
inlineconstexprnoexcept

Replaces the contents with copies of the characters in the range [ first , last ).

◆ assign() [6/8]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto assign ( size_type count,
Char ch ) -> basic_inplace_string&
inlineconstexprnoexcept

Replaces the contents with count copies of character ch.

◆ assign() [7/8]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
template<typename StringView>
requires string_view_like<StringView>
auto assign ( StringView const & view) -> basic_inplace_string&
inlineconstexprnoexcept

Implicitly converts view to a string view sv, then replaces the contents with the characters from sv.

◆ assign() [8/8]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
template<typename StringView>
requires string_view_like<StringView>
auto assign ( StringView const & view,
size_type pos,
size_type count = npos ) -> basic_inplace_string&
inlineconstexprnoexcept

Implicitly converts view to a string view sv, then replaces the contents with the characters from the subview [ pos, pos + count ) of sv.

◆ back() [1/2]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto back ( ) const -> const_reference
inlinenodiscardconstexprnoexcept

Accesses the last character.

◆ back() [2/2]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto back ( ) -> reference
inlinenodiscardconstexprnoexcept

Accesses the last character.

◆ begin() [1/2]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto begin ( ) const -> const_iterator
inlinenodiscardconstexprnoexcept

Returns an const iterator to the beginning.

◆ begin() [2/2]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto begin ( ) -> iterator
inlineconstexprnoexcept

Returns an iterator to the beginning.

◆ c_str()

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto c_str ( ) const -> const_pointer
inlinenodiscardconstexprnoexcept

Returns a pointer to a null-terminated character array.

The data is equivalent to those stored in the string. The pointer is such that the range [c_str(); c_str() + size()] is valid and the values in it correspond to the values stored in the string with an additional null character after the last position.

◆ capacity()

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto capacity ( ) const -> size_type
inlinenodiscardconstexprnoexcept

Returns the number of characters that can be held in allocated storage, NOT including the null terminator.

◆ cbegin()

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto cbegin ( ) const -> const_iterator
inlinenodiscardconstexprnoexcept

Returns an const iterator to the beginning.

◆ cend()

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto cend ( ) const -> const_iterator
inlinenodiscardconstexprnoexcept

Returns an const iterator to the end.

◆ clear()

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto clear ( ) -> void
inlineconstexprnoexcept

Removes all characters from the string. Sets size to 0 and overrides the buffer with zeros.

◆ compare() [1/10]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto compare ( basic_inplace_string< Char, Capacity, Traits > const & str) const -> int
inlinenodiscardconstexprnoexcept

Compares this string to str.

◆ compare() [2/10]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
template<size_type OtherCapacity>
auto compare ( basic_inplace_string< Char, OtherCapacity, traits_type > const & str) const -> int
inlinenodiscardconstexprnoexcept

Compares this string to str with other capacity.

◆ compare() [3/10]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto compare ( const_pointer s) const -> int
inlinenodiscardconstexpr

Compares this string to the null-terminated character sequence beginning at the character pointed to by s with length traits_type::length(s).

◆ compare() [4/10]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto compare ( size_type const pos,
size_type const count,
basic_inplace_string< Char, Capacity, Traits > const & str ) const -> int
inlinenodiscardconstexpr

Compares a [pos, pos+count) substring of this string to str. If count > size() - pos the substring is [pos, size()).

◆ compare() [5/10]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto compare ( size_type const pos,
size_type const count,
const_pointer s ) const -> int
inlinenodiscardconstexpr

Compares a [pos1, pos1+count1) substring of this string to the null-terminated character sequence beginning at the character pointed to by s with length traits_type::length(s). If count1 > size() - pos1 the substring is [pos1, size()).

◆ compare() [6/10]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto compare ( size_type const pos1,
size_type const count1,
basic_inplace_string< Char, Capacity, Traits > const & str,
size_type const pos2,
size_type const count2 = npos ) const -> int
inlinenodiscardconstexpr

Compares a [pos1, pos1+count1) substring of this string to a substring [pos2, pos2+count2) of str. If count1 > size() - pos1 the first substring is [pos1, size()). Likewise, count2 > str.size() - pos2 the second substring is [pos2, str.size()).

◆ compare() [7/10]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto compare ( size_type const pos1,
size_type const count1,
const_pointer s,
size_type const count2 ) const -> int
inlinenodiscardconstexpr

Compares a [pos1, pos1+count1) substring of this string to the characters in the range [s, s + count2). If count1 > size() - pos1 the substring is [pos1, size()). (Note: the characters in the range [s, s + count2) may include null characters.)

◆ compare() [8/10]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
template<typename StringView>
requires string_view_like<StringView>
auto compare ( size_type pos1,
size_type count1,
StringView const & view ) const -> int
inlinenodiscardconstexprnoexcept

Implicitly converts view to a string view sv, then compares a [pos1, pos1+count1) substring of this string to sv.

◆ compare() [9/10]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
template<typename StringView>
requires string_view_like<StringView>
auto compare ( size_type pos1,
size_type count1,
StringView const & view,
size_type pos2,
size_type count2 = npos ) const -> int
inlinenodiscardconstexprnoexcept

Implicitly converts view to a string view sv, then compares a [pos1, pos1+count1) substring of this string to a substring [pos2, pos2+count2) of sv.

◆ compare() [10/10]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
template<typename StringView>
requires string_view_like<StringView>
auto compare ( StringView const & view) const -> int
inlinenodiscardconstexprnoexcept

Implicitly converts view to a string view sv, then compares the content of this string to sv.

◆ contains() [1/3]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto contains ( Char c) const -> bool
inlinenodiscardconstexprnoexcept

Checks if the string contains the given substring.

◆ contains() [2/3]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto contains ( Char const * s) const -> bool
inlinenodiscardconstexpr

Checks if the string contains the given substring.

◆ contains() [3/3]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto contains ( etl::basic_string_view< Char, Traits > sv) const -> bool
inlinenodiscardconstexprnoexcept

Checks if the string contains the given substring.

◆ copy()

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto copy ( pointer destination,
size_type count,
size_type pos = 0 ) const -> size_type
inlineconstexpr

Copies a substring [pos, pos+count) to character string pointed to by dest. If the requested substring lasts past the end of the string, or if count == npos, the copied substring is [pos, size()). The resulting character string is not null-terminated.

If pos is greater then size(), nothing will be copied.

Returns
Number of characters copied.

◆ crbegin()

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto crbegin ( ) const -> const_reverse_iterator
inlinenodiscardconstexprnoexcept

Returns a reverse iterator to the first character of the reversed string. It corresponds to the last character of the non-reversed string.

◆ crend()

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto crend ( ) const -> const_reverse_iterator
inlinenodiscardconstexprnoexcept

Returns a reverse iterator to the first character of the reversed string. It corresponds to the last character of the non-reversed string.

◆ data() [1/2]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto data ( ) const -> const_pointer
inlinenodiscardconstexprnoexcept

Returns a pointer to the underlying array serving as character storage. The pointer is such that the range [data(); data() + size()) is valid and the values in it correspond to the values stored in the string.

Always null-terminated.

◆ data() [2/2]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto data ( ) -> pointer
inlinenodiscardconstexprnoexcept

Returns a pointer to the underlying array serving as character storage. The pointer is such that the range [data(); data() + size()) is valid and the values in it correspond to the values stored in the string.

Always null-terminated.

◆ empty()

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto empty ( ) const -> bool
inlinenodiscardconstexprnoexcept

Checks whether the string is empty.

◆ end() [1/2]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto end ( ) const -> const_iterator
inlinenodiscardconstexprnoexcept

Returns an const iterator to the end.

◆ end() [2/2]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto end ( ) -> iterator
inlineconstexprnoexcept

Returns an iterator to the end.

◆ ends_with() [1/3]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto ends_with ( basic_string_view< Char, Traits > sv) const -> bool
inlinenodiscardconstexprnoexcept

Checks if the string ends with the given prefix.

◆ ends_with() [2/3]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto ends_with ( Char c) const -> bool
inlinenodiscardconstexprnoexcept

Checks if the string ends with the given prefix.

◆ ends_with() [3/3]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto ends_with ( const_pointer str) const -> bool
inlinenodiscardconstexpr

Checks if the string ends with the given prefix.

◆ erase() [1/3]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto erase ( const_iterator first,
const_iterator last ) -> iterator
inlineconstexprnoexcept

Removes the characters in the range [first, last).

Returns
iterator pointing to the character last pointed to before the erase, or end() if no such character exists.

◆ erase() [2/3]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto erase ( const_iterator position) -> iterator
inlineconstexprnoexcept

Removes the character at position.

Returns
iterator pointing to the character immediately following the character erased, or end() if no such character exists.

◆ erase() [3/3]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto erase ( size_type index = 0,
size_type count = npos ) -> basic_inplace_string&
inlineconstexprnoexcept

Removes min(count, size() - index) characters starting at index.

Returns
*this

◆ find() [1/4]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto find ( basic_inplace_string< Char, Capacity, Traits > const & str,
size_type pos = 0 ) const -> size_type
inlinenodiscardconstexprnoexcept

Finds the first substring equal to the given character sequence. Search begins at pos, i.e. the found substring must not begin in a position preceding pos.

https://en.cppreference.com/w/cpp/string/basic_string/find

Returns
Position of the first character of the found substring or npos if no such substring is found.

◆ find() [2/4]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto find ( Char ch,
size_type pos = 0 ) const -> size_type
inlinenodiscardconstexprnoexcept

Finds the first substring equal to the given character sequence. Search begins at pos, i.e. the found substring must not begin in a position preceding pos.

https://en.cppreference.com/w/cpp/string/basic_string/find

Returns
Position of the first character of the found substring or npos if no such substring is found.

◆ find() [3/4]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto find ( const_pointer s,
size_type pos,
size_type count ) const -> size_type
inlinenodiscardconstexprnoexcept

Finds the first substring equal to the given character sequence. Search begins at pos, i.e. the found substring must not begin in a position preceding pos.

https://en.cppreference.com/w/cpp/string/basic_string/find

Returns
Position of the first character of the found substring or npos if no such substring is found.

◆ find() [4/4]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto find ( const_pointer s,
size_type pos = 0 ) const -> size_type
inlinenodiscardconstexprnoexcept

Finds the first substring equal to the given character sequence. Search begins at pos, i.e. the found substring must not begin in a position preceding pos.

https://en.cppreference.com/w/cpp/string/basic_string/find

Returns
Position of the first character of the found substring or npos if no such substring is found.

◆ find_first_not_of() [1/4]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto find_first_not_of ( basic_inplace_string< Char, Capacity, Traits > const & str,
size_type pos = 0 ) const -> size_type
inlinenodiscardconstexprnoexcept

Finds the first character not equal to any of the characters in the given character sequence.

Returns
Position of the first character not equal to any of the characters in the given string, or npos if no such character is found.

◆ find_first_not_of() [2/4]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto find_first_not_of ( Char ch,
size_type pos = 0 ) const -> size_type
inlinenodiscardconstexprnoexcept

Finds the first character not equal to any of the characters in the given character sequence.

Returns
Position of the first character not equal to any of the characters in the given string, or npos if no such character is found.

◆ find_first_not_of() [3/4]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto find_first_not_of ( Char const * s,
size_type pos ) const -> size_type
inlinenodiscardconstexpr

Finds the first character not equal to any of the characters in the given character sequence.

Returns
Position of the first character not equal to any of the characters in the given string, or npos if no such character is found.

◆ find_first_not_of() [4/4]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto find_first_not_of ( Char const * s,
size_type pos,
size_type count ) const -> size_type
inlinenodiscardconstexpr

Finds the first character not equal to any of the characters in the given character sequence.

Returns
Position of the first character not equal to any of the characters in the given string, or npos if no such character is found.

◆ find_first_of() [1/5]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto find_first_of ( basic_inplace_string< Char, Capacity, Traits > const & str,
size_type pos = 0 ) const -> size_type
inlinenodiscardconstexprnoexcept

Finds the first character equal to one of the characters in the given character sequence. The search considers only the interval [pos, size()). If the character is not present in the interval, npos will be returned.

◆ find_first_of() [2/5]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto find_first_of ( basic_string_view< Char, traits_type > str,
size_type pos = 0 ) const -> size_type
inlinenodiscardconstexprnoexcept

Finds the first character equal to one of the characters in the given character sequence. The search considers only the interval [pos, size()). If the character is not present in the interval, npos will be returned.

◆ find_first_of() [3/5]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto find_first_of ( Char ch,
size_type pos = 0 ) const -> size_type
inlinenodiscardconstexprnoexcept

Finds the first character equal to one of the characters in the given character sequence. The search considers only the interval [pos, size()). If the character is not present in the interval, npos will be returned.

◆ find_first_of() [4/5]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto find_first_of ( const_pointer s,
size_type pos,
size_type count ) const -> size_type
inlinenodiscardconstexpr

Finds the first character equal to one of the characters in the given character sequence. The search considers only the interval [pos, size()). If the character is not present in the interval, npos will be returned.

◆ find_first_of() [5/5]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto find_first_of ( const_pointer s,
size_type pos = 0 ) const -> size_type
inlinenodiscardconstexpr

Finds the first character equal to one of the characters in the given character sequence. The search considers only the interval [pos, size()). If the character is not present in the interval, npos will be returned.

◆ find_last_not_of() [1/4]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto find_last_not_of ( basic_inplace_string< Char, Capacity, Traits > const & str,
size_type pos = 0 ) const -> size_type
inlinenodiscardconstexprnoexcept

Finds the last character equal to none of the characters in the given character sequence. The search considers only the interval [0, pos]. If the character is not present in the interval, npos will be returned.

◆ find_last_not_of() [2/4]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto find_last_not_of ( Char c,
size_type pos = 0 ) const -> size_type
inlinenodiscardconstexprnoexcept

Finds the last character equal to none of the characters in the given character sequence. The search considers only the interval [0, pos]. If the character is not present in the interval, npos will be returned.

◆ find_last_not_of() [3/4]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto find_last_not_of ( Char const * s,
size_type pos,
size_type count ) const -> size_type
inlinenodiscardconstexpr

Finds the last character equal to none of the characters in the given character sequence. The search considers only the interval [0, pos]. If the character is not present in the interval, npos will be returned.

◆ find_last_not_of() [4/4]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto find_last_not_of ( Char const * s,
size_type pos = 0 ) const -> size_type
inlinenodiscardconstexpr

Finds the last character equal to none of the characters in the given character sequence. The search considers only the interval [0, pos]. If the character is not present in the interval, npos will be returned.

◆ find_last_of() [1/4]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto find_last_of ( basic_inplace_string< Char, Capacity, Traits > const & str,
size_type pos = 0 ) const -> size_type
inlinenodiscardconstexprnoexcept

Finds the last character equal to one of characters in the given character sequence. The exact search algorithm is not specified. The search considers only the interval [0, pos]. If the character is not present in the interval, npos will be returned.

◆ find_last_of() [2/4]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto find_last_of ( Char c,
size_type pos = 0 ) const -> size_type
inlinenodiscardconstexprnoexcept

Finds the last character equal to one of characters in the given character sequence. The exact search algorithm is not specified. The search considers only the interval [0, pos]. If the character is not present in the interval, npos will be returned.

◆ find_last_of() [3/4]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto find_last_of ( Char const * s,
size_type pos,
size_type count ) const -> size_type
inlinenodiscardconstexpr

Finds the last character equal to one of characters in the given character sequence. The exact search algorithm is not specified. The search considers only the interval [0, pos]. If the character is not present in the interval, npos will be returned.

◆ find_last_of() [4/4]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto find_last_of ( Char const * s,
size_type pos = 0 ) const -> size_type
inlinenodiscardconstexpr

Finds the last character equal to one of characters in the given character sequence. The exact search algorithm is not specified. The search considers only the interval [0, pos]. If the character is not present in the interval, npos will be returned.

◆ front() [1/2]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto front ( ) const -> const_reference
inlinenodiscardconstexprnoexcept

Accesses the first character.

◆ front() [2/2]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto front ( ) -> reference
inlinenodiscardconstexprnoexcept

Accesses the first character.

◆ full()

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto full ( ) const -> bool
inlinenodiscardconstexprnoexcept

Checks whether the string is full. i.e. size() == capacity()

◆ insert() [1/7]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto insert ( size_type const index,
basic_inplace_string< Char, Capacity, Traits > const & str ) -> basic_inplace_string&
inlineconstexprnoexcept

Inserts string str at the position index.

◆ insert() [2/7]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto insert ( size_type const index,
basic_inplace_string< Char, Capacity, Traits > const & str,
size_type const indexStr,
size_type const count = npos ) -> basic_inplace_string&
inlineconstexprnoexcept

Inserts a string, obtained by str.substr(index_str, count) at the position index.

◆ insert() [3/7]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto insert ( size_type const index,
const_pointer s ) -> basic_inplace_string&
inlineconstexprnoexcept

Inserts null-terminated character string pointed to by s at the position index.

◆ insert() [4/7]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto insert ( size_type const index,
const_pointer s,
size_type const count ) -> basic_inplace_string&
inlineconstexprnoexcept

Inserts the characters in the range [s, s+count) at the position index. The range can contain null characters.

◆ insert() [5/7]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto insert ( size_type const index,
size_type const count,
Char const ch ) -> basic_inplace_string&
inlineconstexprnoexcept

Inserts count copies of character ch at the position index.

◆ insert() [6/7]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
template<typename StringView>
requires string_view_like<StringView>
auto insert ( size_type const index,
StringView const & view,
size_type const indexStr,
size_type const count = npos ) -> basic_inplace_string&
inlineconstexprnoexcept

Implicitly converts view to a string view sv, then inserts, before the element (if any) pointed by pos, the characters from the subview [index_str, index_str+count) of sv.

◆ insert() [7/7]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
template<typename StringView>
requires string_view_like<StringView>
auto insert ( size_type const pos,
StringView const & view ) -> basic_inplace_string&
inlineconstexprnoexcept

Implicitly converts view to a string view sv, then inserts the elements from sv before the element (if any) pointed by pos.

◆ length()

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto length ( ) const -> size_type
inlinenodiscardconstexprnoexcept

Returns the number of characters.

◆ max_size()

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto max_size ( ) const -> size_type
inlinenodiscardconstexprnoexcept

Returns the number of characters that can be held in allocated storage, NOT including the null terminator.

◆ operator basic_string_view< Char, traits_type >()

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
operator basic_string_view< Char, traits_type > ( ) const
inlinenodiscardconstexprnoexcept

◆ operator+=() [1/4]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto operator+= ( basic_inplace_string< Char, Capacity, Traits > const & str) -> basic_inplace_string&
inlineconstexprnoexcept

Appends string str.

◆ operator+=() [2/4]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto operator+= ( Char ch) -> basic_inplace_string&
inlineconstexprnoexcept

Appends character ch.

◆ operator+=() [3/4]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto operator+= ( const_pointer s) -> basic_inplace_string&
inlineconstexprnoexcept

Appends the null-terminated character string pointed to by s.

◆ operator+=() [4/4]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
template<typename StringView>
requires string_view_like<StringView>
auto operator+= ( StringView const & view) -> basic_inplace_string&
inlineconstexprnoexcept

Implicitly converts view to a string view sv, then appends characters in the string view sv.

◆ operator=() [1/6]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto operator= ( basic_inplace_string< Char, Capacity, Traits > && ) -> basic_inplace_string &=default
constexprdefaultnoexcept

Defaulted move assignment.

◆ operator=() [2/6]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto operator= ( basic_inplace_string< Char, Capacity, Traits > const & ) -> basic_inplace_string &=default
constexprdefaultnoexcept

Defaulted copy assignment.

◆ operator=() [3/6]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto operator= ( Char ch) -> basic_inplace_string&
inlineconstexprnoexcept

Replaces the contents with character ch.

◆ operator=() [4/6]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto operator= ( const_pointer s) -> basic_inplace_string&
inlineconstexprnoexcept

Replaces the contents with those of null-terminated character string pointed to by s.

◆ operator=() [5/6]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto operator= ( nullptr_t ) -> basic_inplace_string &=delete
constexprdelete

◆ operator=() [6/6]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
template<typename StringView>
requires string_view_like<StringView>
auto operator= ( StringView const & view) -> basic_inplace_string&
inlineconstexprnoexcept

Implicitly converts view to a string view sv, then replaces the contents with those of the sv.

◆ operator[]() [1/2]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto operator[] ( size_type index) const -> const_reference
inlineconstexprnoexcept

Accesses the specified character without bounds checking.

◆ operator[]() [2/2]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto operator[] ( size_type index) -> reference
inlineconstexprnoexcept

Accesses the specified character without bounds checking.

◆ pop_back()

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto pop_back ( ) -> void
inlineconstexprnoexcept

Removes the last character from the string.

Precondition
size() != 0

◆ push_back()

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto push_back ( Char ch) -> void
inlineconstexprnoexcept

Appends the given character ch to the end of the string.

Precondition
size() < capacity()

◆ rbegin() [1/2]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto rbegin ( ) const -> const_reverse_iterator
inlinenodiscardconstexprnoexcept

Returns a reverse iterator to the first character of the reversed string. It corresponds to the last character of the non-reversed string.

◆ rbegin() [2/2]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto rbegin ( ) -> reverse_iterator
inlinenodiscardconstexprnoexcept

Returns a reverse iterator to the first character of the reversed string. It corresponds to the last character of the non-reversed string.

◆ rend() [1/2]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto rend ( ) const -> const_reverse_iterator
inlinenodiscardconstexprnoexcept

Returns a reverse iterator to the first character of the reversed string. It corresponds to the last character of the non-reversed string.

◆ rend() [2/2]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto rend ( ) -> reverse_iterator
inlinenodiscardconstexprnoexcept

Returns a reverse iterator to the first character of the reversed string. It corresponds to the last character of the non-reversed string.

◆ replace() [1/8]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto replace ( const_iterator first,
const_iterator last,
basic_inplace_string< Char, Capacity, Traits > const & str ) -> basic_inplace_string&
inlineconstexpr

Replaces the part of the string indicated [first, last) with a new string.

◆ replace() [2/8]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto replace ( const_iterator first,
const_iterator last,
Char const * str ) -> basic_inplace_string&
inlineconstexpr

◆ replace() [3/8]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto replace ( const_iterator first,
const_iterator last,
Char const * str,
size_type count2 ) -> basic_inplace_string&
inlineconstexpr

◆ replace() [4/8]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto replace ( const_iterator first,
const_iterator last,
size_type count2,
Char ch ) -> basic_inplace_string&
inlineconstexpr

◆ replace() [5/8]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto replace ( size_type pos,
size_type count,
basic_inplace_string< Char, Capacity, Traits > const & str ) -> basic_inplace_string&
inlineconstexpr

Replaces the part of the string indicated [pos, pos + count) with a new string.

◆ replace() [6/8]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto replace ( size_type pos,
size_type count,
basic_inplace_string< Char, Capacity, Traits > const & str,
size_type pos2,
size_type count2 = npos ) -> basic_inplace_string&
inlineconstexpr

◆ replace() [7/8]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto replace ( size_type pos,
size_type count,
Char const * str ) -> basic_inplace_string&
inlineconstexpr

◆ replace() [8/8]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto replace ( size_type pos,
size_type count,
Char const * str,
size_type count2 ) -> basic_inplace_string&
inlineconstexpr

◆ reserve()

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
constexpr auto reserve ( size_type ) -> void
inlinestaticconstexpr

Reserve is a nop, since the capacity is fixed.

◆ resize() [1/2]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto resize ( size_type count) -> void
inlineconstexprnoexcept

Resizes the string to contain count characters.

If the current size is less than count, additional characters are appended, maximum up to it's capacity. If the current size is greater than count, the string is reduced to its first count elements.

◆ resize() [2/2]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto resize ( size_type count,
Char ch ) -> void
inlineconstexprnoexcept

Resizes the string to contain count characters.

If the current size is less than count, additional characters are appended, maximum up to it's capacity. If the current size is greater than count, the string is reduced to its first count elements.

◆ rfind() [1/4]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto rfind ( basic_inplace_string< Char, Capacity, Traits > const & str,
size_type pos = 0 ) const -> size_type
inlinenodiscardconstexprnoexcept

Finds the last substring equal to the given character sequence. Search begins at pos, i.e. the found substring must not begin in a position following pos. If npos or any value not smaller than size()-1 is passed as pos, whole string will be searched.

https://en.cppreference.com/w/cpp/string/basic_string/rfind

Returns
Position of the first character of the found substring or npos if no such substring is found. Note that this is an offset from the start of the string, not the end.

◆ rfind() [2/4]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto rfind ( Char ch,
size_type pos = 0 ) const -> size_type
inlinenodiscardconstexprnoexcept

Finds the last substring equal to the given character sequence. Search begins at pos, i.e. the found substring must not begin in a position following pos. If npos or any value not smaller than size()-1 is passed as pos, whole string will be searched.

https://en.cppreference.com/w/cpp/string/basic_string/rfind

Returns
Position of the first character of the found substring or npos if no such substring is found. Note that this is an offset from the start of the string, not the end.

◆ rfind() [3/4]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto rfind ( const_pointer s,
size_type pos,
size_type count ) const -> size_type
inlinenodiscardconstexprnoexcept

Finds the last substring equal to the given character sequence. Search begins at pos, i.e. the found substring must not begin in a position following pos. If npos or any value not smaller than size()-1 is passed as pos, whole string will be searched.

https://en.cppreference.com/w/cpp/string/basic_string/rfind

Returns
Position of the first character of the found substring or npos if no such substring is found. Note that this is an offset from the start of the string, not the end.
Bug
See tests.

◆ rfind() [4/4]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto rfind ( const_pointer s,
size_type pos = 0 ) const -> size_type
inlinenodiscardconstexprnoexcept

Finds the last substring equal to the given character sequence. Search begins at pos, i.e. the found substring must not begin in a position following pos. If npos or any value not smaller than size()-1 is passed as pos, whole string will be searched.

https://en.cppreference.com/w/cpp/string/basic_string/rfind

Returns
Position of the first character of the found substring or npos if no such substring is found. Note that this is an offset from the start of the string, not the end.

◆ shrink_to_fit()

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
constexpr auto shrink_to_fit ( ) -> void
inlinestaticconstexpr

Shrink to fit is a nop, since the capacity is fixed.

◆ size()

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto size ( ) const -> size_type
inlinenodiscardconstexprnoexcept

Returns the number of characters.

◆ starts_with() [1/3]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto starts_with ( basic_string_view< Char, Traits > sv) const -> bool
inlinenodiscardconstexprnoexcept

Checks if the string begins with the given prefix.

◆ starts_with() [2/3]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto starts_with ( Char c) const -> bool
inlinenodiscardconstexprnoexcept

Checks if the string begins with the given prefix.

◆ starts_with() [3/3]

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto starts_with ( const_pointer s) const -> bool
inlinenodiscardconstexpr

Checks if the string begins with the given prefix.

◆ substr()

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto substr ( size_type pos = 0,
size_type count = npos ) const -> basic_inplace_string
inlinenodiscardconstexpr

Returns a substring [pos, pos+count). If the requested substring extends past the end of the string, or if count == npos, the returned substring is [pos, size()).

If pos is greater then size(), an empty string will be returned.

◆ swap()

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
auto swap ( basic_inplace_string< Char, Capacity, Traits > & other) -> void
inlineconstexprnoexcept

Exchanges the contents of the string with those of other. All iterators and references may be invalidated.

Member Data Documentation

◆ npos

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
size_type npos = numeric_limits<size_type>::max()
staticconstexpr

This is a special value equal to the maximum value representable by the type size_type. The exact meaning depends on context, but it is generally used either as end of string indicator by the functions that expect a string index or as the error indicator by the functions that return a string index.

◆ string_view_like

template<typename Char, etl::size_t Capacity, typename Traits = etl::char_traits<Char>>
template<typename T>
bool string_view_like
staticconstexpr
Initial value:

The documentation for this struct was generated from the following file: