string_view_base

Common functionality for string views

Synopsis

class string_view_base ;

Declared in file <boost/url/grammar/string_view_base.hpp> at line 36

Types

Name Description
traits_type

The character traits

value_type

The value type

pointer

The pointer type

const_pointer

The const pointer type

reference

The reference type

const_reference

The const reference type

const_iterator

The const iterator type

iterator

The iterator type

const_reverse_iterator

The const reverse iterator type

reverse_iterator

The reverse iterator type

size_type

The size type

difference_type

The difference type

Member Functions

Name Description
operator string_view

Conversion

operator string

Conversion

begin

Return an iterator to the beginning

end

Return an iterator to the end

cbegin

Return an iterator to the beginning

cend

Return an iterator to the end

rbegin
rend
crbegin
crend
size

Return the size

length

Return the size

max_size

Return the maximum allowed size

empty

Return true if the string is empty

operator[]

Access a character

at

Access a character

front

Return the first character

back

Return the last character

data

Return a pointer to the character buffer

copy

Copy the characters to another buffer

substr

Return a view to part of the string

compare

Return the result of comparing to another string

compare

Return the result of comparing to another string

compare

Return the result of comparing to another string

compare

Return the result of comparing to another string

compare

Return the result of comparing to another string

compare

Return the result of comparing to another string

starts_with

Return true if a matching prefix exists

starts_with

Return true if a matching prefix exists

starts_with

Return true if a matching prefix exists

ends_with

Return true if a matching suffix exists

ends_with

Return true if a matching suffix exists

ends_with

Return true if a matching suffix exists

find

Return the position of matching characters

find

Return the position of matching characters

find

Return the position of matching characters

find

Return the position of matching characters

rfind

Return the position of matching characters

rfind

Return the position of matching characters

rfind

Return the position of matching characters

rfind

Return the position of matching characters

find_first_of

Return the position of the first match

find_first_of

Return the position of the first match

find_first_of

Return the position of the first match

find_first_of

Return the position of the first match

find_last_of

Return the position of the last match

find_last_of

Return the position of the last match

find_last_of

Return the position of the last match

find_last_of

Return the position of the last match

find_first_not_of

Return the position of the first non-match

find_first_not_of

Return the position of the first non-match

find_first_not_of

Return the position of the first non-match

find_first_not_of

Return the position of the first non-match

find_last_not_of

Return the position of the last non-match

find_last_not_of

Return the position of the last non-match

find_last_not_of

Return the position of the last non-match

find_last_not_of

Return the position of the last non-match

contains

Return true if matching characters are found

contains

Return true if matching characters are found

contains

Return true if matching characters are found

Description

This base class is used to provide common member functions for reference types that behave like string views. This cannot be instantiated directly; Instead, derive from the type and provide constructors which offer any desired preconditions and invariants.