### Check if string starts with a given prefix (C++) Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/starts_with/overload3 Determines if the current string begins with the characters pointed to by 's'. The comparison is based on the length of the string at 's'. This function has linear complexity. ```cpp bool starts_with( const_pointer s) const; ``` -------------------------------- ### Find First Occurrence of Characters in basic_static_string Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/find_first_of/overload3 Finds the first occurrence of any character within the specified range. The search starts at a given position and has a linear complexity. It returns the index of the first match or npos if no match is found. The function takes a pointer to the characters to search for, the starting position, and the length of the character string. ```cpp size_type find_first_of( const_pointer s, size_type pos, size_type n) const; ``` -------------------------------- ### Get Iterator to Beginning of basic_static_string (C++) Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/begin Returns an iterator pointing to the beginning of the basic_static_string. Overloads are provided for both mutable and const access. ```cpp iterator begin(); const_iterator begin() const; ``` -------------------------------- ### Substring Copy Constructor - Boost basic_static_string Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/basic_static_string Creates a basic_static_string from a substring of another basic_static_string starting at a given position. Supports copying with optional count parameter to limit the number of characters copied. ```cpp template< std::size_t M> constexpr basic_static_string( const basic_static_string< M, CharT, Traits >& other, size_type pos); template< std::size_t M> constexpr basic_static_string( const basic_static_string< M, CharT, Traits >& other, size_type pos, size_type count); ``` -------------------------------- ### basic_static_string Constructor (Substring) Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/basic_static_string/overload3 Constructs a basic_static_string with a substring from another basic_static_string. The substring is defined by the starting position 'pos' and extends to the end of the 'other' string. This constructor is part of the Boost C++ Libraries. ```cpp template< std::size_t M> constexpr basic_static_string( const basic_static_string< M, CharT, Traits >& other, size_type pos); ``` -------------------------------- ### basic_static_string::front() - Get First Character (C++) Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/front/overload2 Returns a reference to the first character of a basic_static_string. This operation has constant complexity and requires the string not to be empty. ```cpp const_reference front() const; ``` -------------------------------- ### Find substring by pointer and length in basic_static_string Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/find Searches for the first occurrence of a null-terminated substring specified by pointer and length within the static string. Requires both the starting position and length parameters to be specified. ```cpp size_type find( const_pointer s, size_type pos, size_type n) const; ``` -------------------------------- ### Get Iterator to Beginning (basic_static_string::cbegin) Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/cbegin The `cbegin()` function returns a constant iterator pointing to the first character of the `basic_static_string`. This is useful for iterating over the string's contents without the possibility of modification. It takes no arguments and is a const member function. ```cpp const_iterator cbegin() const; ``` -------------------------------- ### Get Iterator to Beginning of basic_static_string (C++) Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/begin/overload1 Returns an iterator pointing to the beginning of the `basic_static_string`. This function is part of the Boost static string library and does not have external dependencies beyond the Boost library itself. ```cpp iterator begin(); ``` -------------------------------- ### Check if string starts with a string view (C++) Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/starts_with/overload1 The basic_static_string::starts_with function returns true if the string begins with the provided string view `t`, and false otherwise. Its complexity is linear. It takes a string view as input and returns a boolean. ```cpp template< typename T> bool starts_with( T const& t) const; ``` -------------------------------- ### Construct basic_static_string from Substring (C++) Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/basic_static_string/overload4 This constructor creates a new basic_static_string by copying a specified substring from another basic_static_string. It takes the source string, a starting position, and the number of characters to copy. The source string must be of type basic_static_string< M, CharT, Traits >. ```cpp template<\n std::size_t M>\nconstexpr\nbasic_static_string(\n const basic_static_string< M, CharT, Traits >& other,\n size_type pos,\n size_type count);\n ``` -------------------------------- ### Replace substring with another basic_static_string in C++ Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/replace Replaces a portion of the basic_static_string with content from another basic_static_string. It supports specifying start positions and lengths for both the source and destination parts of the strings. ```C++ template< size_t M> basic_static_string& replace( size_type pos1, size_type n1, const basic_static_string< M, CharT, Traits >& str); template< std::size_t M> basic_static_string& replace( size_type pos1, size_type n1, const basic_static_string< M, CharT, Traits >& str, size_type pos2, size_type n2 = npos); template< std::size_t M> basic_static_string& replace( const_iterator i1, const_iterator i2, const basic_static_string< M, CharT, Traits >& str); ``` -------------------------------- ### Find basic_static_string with different size in basic_static_string Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/find Searches for the first occurrence of another basic_static_string with a different template size parameter M within the current static string. Supports starting from an optional position and returns the matching index or npos. ```cpp template size_type find( const basic_static_string< M, CharT, Traits >& str, size_type pos = 0) const; ``` -------------------------------- ### Find null-terminated substring in basic_static_string Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/find Searches for the first occurrence of a null-terminated C-string within the static string, starting from an optional position. Returns the index of the match or npos if the substring is not found. ```cpp size_type find( const_pointer s, size_type pos = 0) const; ``` -------------------------------- ### Find First Occurrence of Character in basic_static_string Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/find_first_of/overload5 Finds the first occurrence of a specified character within a basic_static_string, starting from a given position. Returns the index of the first match or string::npos if not found. The search complexity is linear. ```cpp size_type find_first_of( value_type c, size_type pos = 0) const; ``` -------------------------------- ### basic_static_string::compare Overload - C-style String Comparison Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/compare/overload6 Compares a substring of the `basic_static_string` with a C-style string. It takes the starting position and count for the substring, and a pointer to the C-style string along with its length. The comparison is lexicographical. ```C++ int compare( size_type pos1, size_type count1, const_pointer s, size_type count2) const; ``` -------------------------------- ### Find Substring in basic_static_string (C++) Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/find/overload2 Searches for the first occurrence of a given substring within a basic_static_string. The search starts from a specified position. Returns the index of the first match or npos if not found. ```cpp template< std::size_t M> size_type find( const basic_static_string< M, CharT, Traits >& str, size_type pos = 0) const; ``` -------------------------------- ### Find Character in basic_static_string (C++) Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/find/overload5 Finds the first occurrence of a character within the string starting at a specified position. Returns the index of the first occurrence or npos if the character is not found. The search has linear complexity. ```C++ size_type find( value_type c, size_type pos = 0) const; ``` -------------------------------- ### basic_static_string::append with Substring Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/append/overload9 Appends a substring to the end of a basic_static_string. The substring is derived from the input object `t` starting at `pos` with a length of `count`. This function provides a strong exception guarantee. ```cpp template< typename T> basic_static_string& append( const T& t, size_type pos, size_type count = npos); // Constraints: // std::is_convertible::value && // !std::is_convertible::value && // !std::is_convertible::value // Throws std::length_error if size() + sv.size() > max_size() ``` -------------------------------- ### Return const reverse iterator - basic_static_string::crbegin Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/crbegin The crbegin() method returns a const_reverse_iterator to the beginning of the basic_static_string. This method enables reverse iteration starting from the end of the string and moving backwards. It is a const-qualified member function, meaning it can be called on const instances of basic_static_string. ```cpp const_reverse_iterator crbegin() const; ``` -------------------------------- ### basic_static_string::find_first_of Overload Synopsis Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/find_first_of/overload2 This C++ synopsis defines an overload for the `find_first_of` method of the `basic_static_string` class. It searches for the first occurrence of any character from a given `basic_static_string` within the current string, starting from a specified position. The complexity is linear, and it returns the index of the first match or `npos` if no match is found. ```cpp template< std::size_t M> size_type find_first_of( const basic_static_string< M, CharT, Traits >& str, size_type pos = 0) const; ``` -------------------------------- ### Find substring in basic_static_string with template parameter Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/find Searches for the first occurrence of a substring specified by a template parameter within the static string. The search begins at the optional starting position and returns the index of the first match or npos if not found. ```cpp template size_type find( const T& t, size_type pos = 0) const; ``` -------------------------------- ### Copy Substring to Destination - C++ Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/copy Copies a specified number of characters from a basic_static_string to a destination buffer. The copy starts at a given position and copies up to 'count' characters or the remaining characters in the string, whichever is smaller. The destination string is not null-terminated. ```cpp size_type copy( pointer dest, size_type count, size_type pos = 0) const; ``` -------------------------------- ### Get First Character - Boost basic_static_string::front() Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/front/overload1 Returns a reference to the first character of a basic_static_string object. This member function provides O(1) constant-time complexity access to the front element. The string must not be empty when calling this function, as per the precondition requirement. ```cpp reference front(); ``` -------------------------------- ### Find First Occurrence of Characters in Static String (C++) Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/find_first_of/overload1 Template member function that searches for the first occurrence of any character from a given set within a basic_static_string starting at a specified position. Constructs a temporary string_view_type object from the input parameter and performs linear-time search, returning the index of the first match or npos if no match is found. ```cpp template< typename T> size_type find_first_of( const T& t, size_type pos = 0) const; ``` -------------------------------- ### Find First of Any Character in Boost.StaticString (C++) Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/find_first_of Finds the first occurrence of any of the characters within the string. This function has overloads to search for characters provided as a generic type `T`, another `basic_static_string`, a C-style string pointer with a length, or a C-style string pointer. It returns the index of the first match or `std::string::npos` if no match is found. The search can optionally start from a specified position. ```cpp template< typename T> size_type find_first_of( const T& t, size_type pos = 0) const; template< std::size_t M> size_type find_first_of( const basic_static_string< M, CharT, Traits >& str, size_type pos = 0) const; size_type find_first_of( const_pointer s, size_type pos, size_type n) const; size_type find_first_of( const_pointer s, size_type pos = 0) const; ``` -------------------------------- ### Find Substring in basic_static_string (C++) Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/find/overload4 Finds the first occurrence of a given C-style string within a basic_static_string, starting the search from a specified position. An empty string is always considered found. The function returns the index of the first occurrence or npos if not found. ```cpp size_type find( const_pointer s, size_type pos = 0) const; ``` -------------------------------- ### Find Last Substring Occurrence - basic_static_string::rfind Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/rfind/overload3 Finds the last occurrence of a specified substring within the basic_static_string. It searches backward from a given position. The function takes a pointer to the substring, its length, and the starting position for the search. ```cpp size_type rfind( const_pointer s, size_type pos, size_type n) const; ``` -------------------------------- ### Get Reverse Iterator: basic_static_string::rbegin (C++) Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/rbegin/overload2 The rbegin() function returns a reverse iterator pointing to the first character of the basic_static_string when iterated in reverse. This is useful for iterating through the string from end to beginning. It takes no arguments and operates on a const basic_static_string object. ```cpp const_reverse_iterator rbegin() const; ``` -------------------------------- ### Find First Non-Matching Character in basic_static_string C++ Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/find_first_not_of/overload5 The find_first_not_of method searches for the first character in a basic_static_string that is not equal to a specified character value, starting from an optional position. It returns the index of the first non-matching character or npos if no such character exists. This operation has linear time complexity. ```cpp size_type find_first_not_of( value_type c, size_type pos = 0) const; ``` -------------------------------- ### Replace Part of basic_static_string Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/replace/overload3 Replaces a specified number of characters starting at a given position with the content of another object. The function constructs a temporary string_view from the input and adjusts the replacement count based on the string's bounds. It guarantees strong exception safety. ```C++ template< typename T> basic_static_string& replace( size_type pos1, size_type n1, const T& t); ``` -------------------------------- ### Initializer List Constructor - Boost basic_static_string Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/basic_static_string Constructs a basic_static_string from an initializer list of characters. Allows brace-initialization syntax for convenient string creation. ```cpp constexpr basic_static_string( std::initializer_list< value_type > init); ``` -------------------------------- ### Get Pointer to String Data - C++ Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/data/overload1 Returns a pointer to the underlying array serving as storage for the basic_static_string. The range starting from this pointer and extending to `data() + size()` is always valid. This function has constant complexity and always returns a non-null pointer. ```cpp pointer data(); ``` -------------------------------- ### Compare Substrings with basic_static_string::compare Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/compare/overload9 Compares a substring of a `basic_static_string` with a portion of another string or string view. It determines the lexicographical order based on character comparison and lengths. The function takes starting positions and counts for both the string and the comparison target, with an optional count for the comparison target. ```cpp template< typename T> int compare( size_type pos1, size_type count1, const T& t, size_type pos2, size_type count2 = npos) const; ``` -------------------------------- ### Get Substring View using basic_static_string::subview (C++) Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/subview The subview function returns a string_view_type object representing a substring. It takes an optional starting position 'pos' and an optional count 'count' to define the substring's length. The default values are 0 for pos and npos for count. It throws std::out_of_range if pos is greater than the string's size. ```cpp string_view_type subview( size_type pos = 0, size_type count = npos) const; ``` -------------------------------- ### Pointer and C-String Constructor - Boost basic_static_string Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/basic_static_string Initializes a basic_static_string from a C-style character pointer. Can construct from a pointer with explicit count or from a null-terminated C-string pointer. ```cpp constexpr basic_static_string( const_pointer s, size_type count); constexpr basic_static_string( const_pointer s); ``` -------------------------------- ### Find First of Single Character in Boost.StaticString (C++) Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/find_first_of Finds the first occurrence of a single specified character within the string. This overload is efficient for searching for a single character value. It returns the index of the first match or `std::string::npos` if the character is not found. The search can optionally start from a specified position. ```cpp size_type find_first_of( value_type c, size_type pos = 0) const; ``` -------------------------------- ### Find First Character Not Of (C++) Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/find_first_not_of/overload4 Finds the first character in the string that is not present within the character set pointed to by `s`, starting the search from index `pos`. The search complexity is linear. Returns the index of the first non-matching character or `npos` if none is found. ```cpp size_type find_first_not_of( const_pointer s, size_type pos = 0) const; ``` -------------------------------- ### Find First Not Of - basic_static_string Template Function Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/find_first_not_of/overload1 Template member function that constructs a temporary string_view object from the input parameter and finds the first character not present in that view, starting from the specified position. Returns the index of the first non-matching character or npos if no such character exists. Linear time complexity. ```cpp template< typename T> size_type find_first_not_of( const T& t, size_type pos = 0) const; ``` -------------------------------- ### Check Prefix with String - basic_static_string::starts_with Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/starts_with Determines if the basic_static_string begins with the provided string. This overload is templated to accept various string-like types. ```cpp template< typename T> bool starts_with( T const& t) const; ``` ```cpp bool starts_with( const_pointer s) const; ``` -------------------------------- ### basic_static_string substr method signature C++ Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/substr The substr method returns a substring of the basic_static_string. It accepts an optional starting position (pos) and optional length (count), with defaults of 0 and npos respectively. The method provides strong exception safety and throws std::out_of_range if pos exceeds the string size. ```cpp basic_static_string substr( size_type pos = 0, size_type count = npos) const; ``` -------------------------------- ### Fill Constructor - Boost basic_static_string Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/basic_static_string Constructs a basic_static_string by repeating a single character a specified number of times. Takes a count and a character value to initialize the string with count copies of the character. ```cpp constexpr basic_static_string( size_type count, value_type ch); ``` -------------------------------- ### basic_static_string::find_first_not_of Template Method in C++ Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/find_first_not_of/overload2 Template method that finds the first character not within a reference static string. Returns the index of the first non-matching character starting from position pos, or npos if all characters match. This method has linear time complexity and is part of the Boost C++ Libraries static_string component. ```cpp template< std::size_t M> size_type find_first_not_of( const basic_static_string< M, CharT, Traits >& str, size_type pos = 0) const; ``` -------------------------------- ### basic_static_string::assign Overload - C++ Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/assign/overload5 Assigns content from a null-terminated character array to the basic_static_string. The string is replaced with the content of the array starting from 's' up to the null terminator. This operation is linear in the length of the string being assigned and provides a strong exception guarantee. ```cpp basic_static_string& assign(const_pointer s); ``` -------------------------------- ### Copy Constructor - Boost basic_static_string Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/basic_static_string Creates a copy of an existing basic_static_string. Supports copying from basic_static_string with the same or different template capacity parameter M. ```cpp constexpr basic_static_string( const basic_static_string& other); template< std::size_t M> constexpr basic_static_string( const basic_static_string< M, CharT, Traits >& other); ``` -------------------------------- ### basic_static_string::find_last_not_of with a single character Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/find_last_not_of Finds the last occurrence of a character that is not equal to the specified character `c`. The search can optionally start from a given position `pos`. ```C++ size_type find_last_not_of( value_type c, size_type pos = npos) const; ``` -------------------------------- ### basic_static_string::replace - Replace characters in a string with a C-style string Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/replace/overload6 Replaces a specified number of characters in a basic_static_string starting at a given position with the content of a null-terminated C-style string. The number of characters replaced is determined by the minimum of the requested count and the available space. This operation provides a strong exception guarantee. ```cpp basic_static_string&\nreplace(\n size_type pos,\n size_type n1,\n const_pointer s\n); ``` -------------------------------- ### Construct Empty basic_static_string (C++) Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/basic_static_string/overload1 This is the default constructor for basic_static_string. It initializes an empty string object. No specific dependencies are required beyond the Boost library itself. The output is an empty basic_static_string object. ```cpp constexpr basic_static_string(); ``` -------------------------------- ### basic_static_string::starts_with Functionality (C++) Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/starts_with/overload2 Checks if the string begins with a specific character. This function has constant complexity and takes a single character as input, returning a boolean value. ```cpp bool starts_with( value_type c) const; ``` -------------------------------- ### Compare Substring with String - C++ Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/compare/overload2 Compares a substring of the current `basic_static_string` with another `basic_static_string`. It first compares a specified number of characters from a starting position and then determines the result based on the sizes of the compared portions if the initial comparison yields equality. The function has linear complexity and offers a strong guarantee for exception safety. ```cpp template< std::size_t M> int compare( size_type pos1, size_type count1, const basic_static_string< M, CharT, Traits >& s) const; ``` -------------------------------- ### basic_static_string Constructor with Initializer List (C++) Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/basic_static_string/overload10 Constructs a basic_static_string object from a std::initializer_list of value_type. This constructor enables easy creation of static strings from literal lists. ```cpp constexpr basic_static_string( std::initializer_list< value_type > init ); ``` -------------------------------- ### basic_static_string Constructor from Character Range (C++) Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/basic_static_string/overload7 Constructs a basic_static_string object from a range of characters specified by input iterators. This constructor is useful for initializing the string with data from various sources like other containers or sequences. ```cpp template< typename InputIterator> constexpr basic_static_string( InputIterator first, InputIterator last); ``` -------------------------------- ### Construct basic_static_string from null-terminated C-string pointer Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/basic_static_string/overload6 Constructor overload that initializes a basic_static_string object from a const_pointer to a null-terminated string. This constexpr constructor allows compile-time string construction. The input string must be null-terminated, and the constructor will copy the string content into the static storage. ```cpp constexpr basic_static_string( const_pointer s); ``` -------------------------------- ### basic_static_string::insert Synopsis Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/insert/overload6 This code snippet shows the synopsis for the basic_static_string::insert function. It takes a const_iterator position and a value_type character as input and returns an iterator. ```cpp iterator insert( const_iterator pos, value_type ch); ``` -------------------------------- ### Get basic_static_string Size (C++) Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/size The size() method returns the number of characters currently stored in the basic_static_string object. This count excludes the null terminator. The operation has constant time complexity. ```C++ size_type size() const; ``` -------------------------------- ### Construct basic_static_string from string_view convertible object Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/basic_static_string/overload11 Template constructor for basic_static_string that accepts any object convertible to string_view_type. This overload (11 of 12) enables flexible initialization by accepting any compatible type. The constructor is constexpr, allowing compile-time string construction. ```cpp template< typename T> constexpr basic_static_string( const T& t); ``` -------------------------------- ### Get String Length - basic_static_string::length (C++) Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/length Returns the number of characters stored in the string, excluding the null terminator. The operation has constant complexity. This function is part of the Boost C++ Libraries. ```cpp size_type length() const; ``` -------------------------------- ### Get Last Character of basic_static_string (C++) Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/back This function returns the last character of a basic_static_string. It is available for both mutable and constant references. No specific dependencies are mentioned, and it takes no arguments, returning a character reference. ```C++ reference back(); const_reference back() const; ``` -------------------------------- ### rfind with const pointer in Boost C++ Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/rfind Overload for rfind that accepts a const pointer to a null-terminated C-style string and searches for its last occurrence. The optional pos parameter specifies the search starting position. ```cpp size_type rfind( const_pointer s, size_type pos = npos) const; ``` -------------------------------- ### Find First Not Of in basic_static_string (C++) Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/find_first_not_of/overload3 Finds the first occurrence of a character that is not within the string pointed to by 's' within the string starting at the index 'pos'. The search considers characters up to length 'n' from 's'. ```cpp size_type find_first_not_of( const_pointer s, size_type pos, size_type n) const; ``` -------------------------------- ### Conversion Constructor - Boost basic_static_string Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/basic_static_string Explicitly constructs a basic_static_string from a generic type T, enabling interoperability with string-like types. Supports substring extraction with optional position and length parameters. ```cpp template< typename T> explicit constexpr basic_static_string( const T& t); template< typename T> constexpr basic_static_string( const T& t, size_type pos, size_type n); ``` -------------------------------- ### swap (2 of 2 overloads) Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__swap/overload2 The swap function allows for the efficient exchange of the contents of two basic_static_string objects. ```APIDOC ## void swap (basic_static_string< N, CharT, Traits >& lhs, basic_static_string< M, CharT, Traits >& rhs) ### Description Exchanges the contents of two `basic_static_string` objects. This operation is typically very efficient as it may only involve swapping internal pointers or metadata, rather than copying characters. ### Method `swap` (free function) ### Endpoint N/A (This is a library function, not a network endpoint) ### Parameters #### Path Parameters None #### Query Parameters None #### Request Body None ### Request Example ```cpp #include boost::static_string<10> str1 = "hello"; boost::static_string<20> str2 = "world!"; boost::swap(str1, str2); // Now str1 contains "world!" and str2 contains "hello" ``` ### Response #### Success Response (void) This function does not return a value. #### Response Example N/A ``` -------------------------------- ### Get Iterator to End of basic_static_string (C++) Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/end Returns an iterator to the end of the basic_static_string. This function has two overloads: one for mutable iterators and one for const iterators. It is a standard library-like function for string manipulation. ```cpp iterator end(); const_iterator end() const; ``` -------------------------------- ### basic_static_string::rfind - Find Last Substring Occurrence Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/rfind/overload1 Finds the last occurrence of a substring within the basic_static_string. It constructs a temporary string_view from the input and searches for its last appearance starting from a specified position. The complexity is linear. ```C++ template< typename T> size_type rfind( const T& t, size_type pos = npos) const; ``` -------------------------------- ### Define static_wstring Alias Template Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string Creates a convenience alias template for basic_static_string with wchar_t type and standard character traits. This template enables fixed-capacity wide character string declarations with compile-time size specification. ```cpp template using static_wstring = basic_static_string>; ``` -------------------------------- ### Get Const Iterator to End of basic_static_string (C++) Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/cend The basic_static_string::cend() function returns a const_iterator pointing to the position after the last character of the string. This is useful for iterating over the string in a read-only manner. It has no parameters and returns a const_iterator. ```cpp const_iterator cend() const; ``` -------------------------------- ### Iterator Range Constructor - Boost basic_static_string Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/basic_static_string Constructs a basic_static_string from a range defined by input iterators. Accepts first and last iterators to copy characters from any container or sequence. ```cpp template< typename InputIterator> constexpr basic_static_string( InputIterator first, InputIterator last); ``` -------------------------------- ### Find Last Substring Occurrence in basic_static_string (C++) Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/rfind/overload4 Finds the last occurrence of a null-terminated string within the basic_static_string. The search starts from a specified position. Returns the index of the first character of the found substring or npos if not found. ```cpp size_type rfind( const_pointer s, size_type pos = npos) const; ``` -------------------------------- ### Define static_string Alias Template Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string Creates a convenience alias template for basic_static_string with char type and standard character traits. This template simplifies declaration of fixed-capacity narrow character strings with compile-time size specification. ```cpp template using static_string = basic_static_string>; ``` -------------------------------- ### Replace Substring in basic_static_string (C++) Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/replace/overload2 Replaces a specified number of characters starting at a given position in a `basic_static_string` with a substring from another `basic_static_string`. This operation has strong exception safety. References, pointers, and iterators to elements may be invalidated. ```C++ template< std::size_t M> basic_static_string& replace( size_type pos1, size_type n1, const basic_static_string< M, CharT, Traits >& str, size_type pos2, size_type n2 = npos); ``` -------------------------------- ### Synopsis of std::hash in C++ Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/std__hash_lt__basic_static_string__gt_ This C++ code snippet shows the synopsis for the std::hash specialization of basic_static_string. It is defined in the header file and is a template struct. ```cpp #include #include template< std::size_t N, typename CharT, typename Traits> struct std::hash< boost::container::pmr::basic_static_string > ``` -------------------------------- ### Convert numeric types to static_wstring C++ Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__to_static_wstring This function converts integer and floating-point types to a `static_wstring`. The size of the output `static_wstring` is dynamically calculated based on the maximum number of digits representable by the input type plus a small buffer. This function is part of the Boost.Static String library and does not have external dependencies beyond standard C++ numeric limits. ```cpp static_wstring< std::numeric_limits< int >::digits10+2 > to_static_wstring( int value); static_wstring< std::numeric_limits< long >::digits10+2 > to_static_wstring( long value); static_wstring< std::numeric_limits< long long >::digits10+2 > to_static_wstring( long long value); static_wstring< std::numeric_limits< unsigned int >::digits10+1 > to_static_wstring( unsigned int value); static_wstring< std::numeric_limits< unsigned long >::digits10+1 > to_static_wstring( unsigned long value); static_wstring< std::numeric_limits< unsigned long long >::digits10+1 > to_static_wstring( unsigned long long value); static_wstring< std::numeric_limits< float >::max_digits10+4 > to_static_wstring( float value); static_wstring< std::numeric_limits< double >::max_digits10+4 > to_static_wstring( double value); static_wstring< std::numeric_limits< long double >::max_digits10+4 > to_static_wstring( long double value); ``` -------------------------------- ### Erase Characters from basic_static_string by Index/Count (C++) Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/erase Removes a specified number of characters from the string starting at a given index. Supports erasing from index 0 to the end of the string if count is `npos`. Returns a reference to the modified string. ```cpp basic_static_string& erase( size_type index = 0, size_type count = npos); ``` -------------------------------- ### Append Substring to basic_static_string (C++) Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/append/overload3 Appends a specified substring from another basic_static_string to the end of the current string. This operation can throw std::length_error if the resulting string exceeds max_size, or std::out_of_range if the starting position is invalid. ```C++ template< std::size_t M> basic_static_string& append( const basic_static_string< M, CharT, Traits >& s, size_type pos, size_type count = npos); ``` -------------------------------- ### Construct basic_static_string from C-string and count (C++) Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/basic_static_string/overload5 This constructor initializes a basic_static_string with the first `count` characters of the null-terminated C-style string `s`. It's useful for creating strings with a defined length from existing character arrays or string literals, potentially including embedded null characters. ```cpp constexpr basic_static_string( const_pointer s, size_type count); ``` -------------------------------- ### Get Max Size of basic_static_string C++ Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/max_size Retrieves the maximum number of characters that can be stored in a basic_static_string, excluding the null terminator. The returned value is always N, representing the fixed capacity. This operation has constant time complexity. ```C++ size_type max_size() const; ``` -------------------------------- ### Boost static_string operator> Overload Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__operator__gt_/overload3 This C++ code snippet defines the synopsis for the 'operator>' overload for `basic_static_string`. It allows comparison between a `basic_static_string` object and a C-style string. The function is defined in the header ``. ```cpp template< std::size_t N, typename CharT, typename Traits> bool operator>( const basic_static_string< N, CharT, Traits >& lhs, const CharT* rhs); ``` -------------------------------- ### Get Iterator to Beginning of basic_static_string (C++) Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/begin/overload2 This function returns a const_iterator pointing to the first character of the basic_static_string. It is a const member function, meaning it does not modify the string. No specific dependencies are mentioned beyond the Boost static_string library itself. ```cpp const_iterator begin() const; ``` -------------------------------- ### operator< Overload for basic_static_string (C++) Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__operator_lt_/overload5 This snippet shows the synopsis for the operator< overload in the Boost static string library. It allows for comparison between a basic_static_string object and another type T. The comparison is defined in the header . ```cpp template<\n std::size_t N,\n typename CharT,\n typename Traits,\n class T>\nbool\noperator<( const basic_static_string< N, CharT, Traits >& lhs,\n const T& rhs);\n ``` -------------------------------- ### basic_static_string::rbegin - C++ Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/rbegin/overload1 Returns a reverse iterator pointing to the first character of the basic_static_string when iterating in reverse. This is useful for algorithms that process sequences from end to beginning. No specific dependencies beyond the basic_static_string class itself are required. ```cpp reverse_iterator rbegin(); ``` -------------------------------- ### Get First Character of basic_static_string (C++) Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/front Returns the first character of a basic_static_string. This function is available in both mutable and constant reference forms, allowing modification or read-only access to the first character. It does not take any arguments and operates on the string instance itself. ```cpp reference front(); const_reference front() const; ``` -------------------------------- ### basic_static_string::rend - C++ Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/rend/overload1 Returns a reverse iterator pointing to the element immediately preceding the beginning of the static string. This is useful for reverse iteration and algorithms. ```cpp reverse_iterator rend(); ``` -------------------------------- ### Convert unsigned int to static_wstring - Boost C++ Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__to_static_wstring/overload4 Converts an unsigned integer value to a static_wstring with a compile-time determined buffer size. The function returns a static_wstring with a capacity calculated from std::numeric_limits::digits10+1, ensuring sufficient space for any unsigned int representation plus null terminator. Defined in the Boost.StaticString header. ```cpp static_wstring< std::numeric_limits< unsigned int >::digits10+1 > to_static_wstring( unsigned int value); ``` -------------------------------- ### Define static_u8string Alias Template (C++20) Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string Creates a convenience alias template for basic_static_string with char8_t type and standard character traits. This template simplifies declaration of fixed-capacity UTF-8 character strings and is available only in C++20 and later standards. ```cpp template using static_u8string = basic_static_string>; ``` -------------------------------- ### Copy Constructor for basic_static_string Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/basic_static_string/overload8 Constexpr copy constructor that creates a new basic_static_string instance from an existing basic_static_string object. This constructor is marked constexpr, allowing it to be evaluated at compile-time when appropriate. It takes a const reference to another basic_static_string of the same type as input. ```cpp constexpr basic_static_string( const basic_static_string& other); ``` -------------------------------- ### Convert to static_string (C++) Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__to_static_string/overload4 Converts an unsigned integer value to a `boost::static_string`. The size of the resulting `static_string` is determined by the number of decimal digits in the maximum value of an `unsigned int`. This function is defined in the `` header. ```cpp static_string< std::numeric_limits< unsigned int >::digits10+1 > to_static_string( unsigned int value); ``` -------------------------------- ### rfind with character value in Boost C++ Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/rfind Overload for rfind that searches for the last occurrence of a single character (value_type) within the static string. Returns the position of the character or npos if not found. The optional pos parameter specifies the search starting position. ```cpp size_type rfind( value_type c, size_type pos = npos) const; ``` -------------------------------- ### Define static_u32string Alias Template Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string Creates a convenience alias template for basic_static_string with char32_t type and standard character traits. This template enables fixed-capacity UTF-32 character string declarations with compile-time size specification. ```cpp template using static_u32string = basic_static_string>; ``` -------------------------------- ### Find Substring in basic_static_string (C++) Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/find/overload3 This function finds the first occurrence of a given string within the basic_static_string. It searches starting from a specified position and returns the index of the first match or a special value indicating no match. The complexity is linear with respect to the string length. ```C++ size_type find( const_pointer s, size_type pos, size_type n) const; ``` -------------------------------- ### Get Pointer to Static String Data (C++) Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/data/overload2 Retrieves a constant pointer to the underlying character array of a basic_static_string. This pointer allows access to the string's content, with the range from `data()` to `data() + size()` being valid. The returned pointer is guaranteed not to be null. ```cpp const_pointer data() const; ``` -------------------------------- ### Prepend Character to basic_static_string (C++) Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__operator_plus_/overload3 This overload of operator+ concatenates a character to the beginning of a basic_static_string. It is defined in the `` header. The function takes a character and a basic_static_string as input and returns a new basic_static_string with the character prepended. ```cpp template< std::size_t N, typename CharT, typename Traits> basic_static_string< N+1, CharT, Traits > operator+( CharT lhs, const basic_static_string< N, CharT, Traits >& rhs); ``` -------------------------------- ### Define static_u16string Alias Template Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string Creates a convenience alias template for basic_static_string with char16_t type and standard character traits. This template simplifies declaration of fixed-capacity UTF-16 character strings with compile-time size specification. ```cpp template using static_u16string = basic_static_string>; ``` -------------------------------- ### rfind with template type in Boost C++ Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/rfind Template overload for rfind that accepts any type T and searches for its last occurrence in the static string. Returns the position of the last match or npos if not found. The optional pos parameter specifies the starting position for the reverse search. ```cpp template size_type rfind( const T& t, size_type pos = npos) const; ``` -------------------------------- ### operator< Overload for Boost Static String (C++) Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__operator_lt_/overload3 This snippet defines the synopsis for the operator< overload in the Boost static string library. It allows for comparison between a basic_static_string object and a C-style string (CharT*). The function is defined in the header and returns a boolean value indicating the lexicographical comparison result. ```cpp template< std::size_t N, typename CharT, typename Traits> bool operator<( const basic_static_string< N, CharT, Traits >& lhs, const CharT* rhs); ``` -------------------------------- ### Define basic_static_string Template Class in C++ Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string Template definition for basic_static_string with three template parameters: N for capacity, CharT for character type, and optional Traits for character traits. Defined in header . This template creates a fixed-capacity string container that behaves like std::string but with compile-time determined size and inline storage. ```cpp template< std::size_t N, typename CharT, typename Traits = std::char_traits> class basic_static_string ``` -------------------------------- ### Get Reverse Iterator to End of basic_static_string (C++) Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/crend The crend() method returns a const_reverse_iterator pointing to the theoretical element following the last element of the basic_static_string. This is commonly used in C++ for iterating through a string in reverse order. No specific dependencies are required beyond the basic_static_string class itself. ```cpp const_reverse_iterator crend() const; ``` -------------------------------- ### Swap Boost.Static String Contents (C++) Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__swap/overload1 The `swap` function exchanges the contents of two `basic_static_string` objects. It requires the `basic_static_string` class template, which is defined in the `` header. This function operates efficiently by swapping internal data pointers or structures. ```C++ template< std::size_t N, typename CharT, typename Traits> void swap( basic_static_string< N, CharT, Traits >& lhs, basic_static_string< N, CharT, Traits >& rhs); ``` -------------------------------- ### Find First Occurrence of Characters in Static String (C++) Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/find_first_of/overload4 The find_first_of method searches for the first occurrence of any character from a null-terminated string `s` within the current static string, beginning at position `pos`. The method uses traits_type::length(s) to determine the length of the search string. It returns the index of the first matching character or npos if no characters match. ```cpp size_type find_first_of( const_pointer s, size_type pos = 0) const; ``` -------------------------------- ### Replace string content in basic_static_string C++ Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/replace/overload5 Replaces rcount characters starting at index pos with characters from a source string {s, s + n2}, where rcount is the minimum of n1 and (size() - pos). This method provides strong exception safety guarantee and invalidates all references, pointers, and iterators to contained elements. ```cpp basic_static_string& replace( size_type pos, size_type n1, const_pointer s, size_type n2); ``` -------------------------------- ### Convert int to static_string in C++ Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__to_static_string/overload1 Converts an integer value to a `static_string` object. This function requires the `` header. It takes an integer as input and returns a `static_string` with a size determined by the decimal digits of the integer type plus two. ```cpp static_string< std::numeric_limits< int >::digits10+2 > to_static_string( int value); ``` -------------------------------- ### basic_static_string::rfind - Find Last Substring Occurrence in C++ Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/rfind/overload2 Template member function that searches for the last occurrence of a substring within a basic_static_string object. Takes a basic_static_string parameter and optional starting position, returning the highest index where the substring matches or npos if not found. Linear time complexity. ```cpp template< std::size_t M> size_type rfind( const basic_static_string< M, CharT, Traits >& str, size_type pos = npos) const; ``` -------------------------------- ### Convert int to static_wstring (C++) Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__to_static_wstring/overload1 Converts an integer value to a `static_wstring`. This function is defined in the `` header. The size of the resulting `static_wstring` is determined by the number of decimal digits in an int plus two. ```cpp #include #include // Example usage: // static_wstring< std::numeric_limits< int >::digits10+2 > result = to_static_wstring(12345); static_wstring< std::numeric_limits< int >::digits10+2 > to_static_wstring( int value); ``` -------------------------------- ### basic_static_string Copy Constructor (C++) Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/basic_static_string/overload9 This is the copy constructor for the basic_static_string class. It creates a new basic_static_string object by copying the contents of another existing basic_static_string object. This overload is templated on the maximum size M of the string being copied. ```C++ template< std::size_t M> constexpr basic_static_string( const basic_static_string< M, CharT, Traits >& other); ``` -------------------------------- ### Find Last Occurrence of Characters in basic_static_string (C++) Source: https://www.boost.org/doc/libs/latest/libs/static_string/doc/html/static_string/ref/boost__static_strings__basic_static_string/find_last_of Finds the last occurrence of any character within the string that is also present in the provided character set or substring. Supports searching for a character set represented by a template type, another basic_static_string, or a C-style string. The search can be limited by a starting position. ```cpp template< typename T> size_type find_last_of( const T& t, size_type pos = npos) const; template< std::size_t M> size_type find_last_of( const basic_static_string< M, CharT, Traits >& str, size_type pos = npos) const; size_type find_last_of( const_pointer s, size_type pos, size_type n) const; size_type find_last_of( const_pointer s, size_type pos = npos) const; ```