QtBase  v6.3.1
Public Types | Public Member Functions | Static Public Member Functions | Friends | List of all members
QAnyStringView Class Reference

#include <qanystringview.h>

Inheritance diagram for QAnyStringView:
Inheritance graph
[legend]

Public Types

typedef qptrdiff difference_type
 
typedef qsizetype size_type
 

Public Member Functions

constexpr QAnyStringView () noexcept
 
constexpr QAnyStringView (std::nullptr_t) noexcept
 
template<typename Char , if_compatible_char< Char > = true>
constexpr QAnyStringView (const Char *str, qsizetype len)
 
template<typename Char , if_compatible_char< Char > = true>
constexpr QAnyStringView (const Char *f, const Char *l)
 
template<typename Pointer , if_compatible_pointer< Pointer > = true>
constexpr QAnyStringView (const Pointer &str) noexcept
 
 QAnyStringView (const QByteArray &str) noexcept
 
 QAnyStringView (const QString &str) noexcept
 
constexpr QAnyStringView (QLatin1String str) noexcept
 
template<typename A , typename B >
 QAnyStringView (const QStringBuilder< A, B > &expr, typename QConcatenable< QStringBuilder< A, B >>::ConvertTo &&capacity={})
 
template<typename Container , if_compatible_container< Container > = true>
constexpr QAnyStringView (const Container &c) noexcept
 
template<typename Char , if_compatible_char< Char > = true>
constexpr QAnyStringView (const Char &c) noexcept
 
constexpr QAnyStringView (const QChar &c) noexcept
 
template<typename Char , typename Container = decltype(QChar::fromUcs4(U'x')), std::enable_if_t< std::is_same_v< Char, char32_t >, bool > = true>
constexpr QAnyStringView (Char c, Container &&capacity={})
 
constexpr QAnyStringView (QStringView v) noexcept
 
template<bool UseChar8T>
constexpr QAnyStringView (QBasicUtf8StringView< UseChar8T > v) noexcept
 
template<typename Visitor >
constexpr decltype(autovisit (Visitor &&v) const
 
QString toString () const
 
constexpr qsizetype size () const noexcept
 
constexpr const voiddata () const noexcept
 
constexpr QChar front () const
 
constexpr QChar back () const
 
constexpr bool empty () const noexcept
 
constexpr qsizetype size_bytes () const noexcept
 
constexpr bool isNull () const noexcept
 
constexpr bool isEmpty () const noexcept
 
constexpr qsizetype length () const noexcept
 

Static Public Member Functions

template<typename Char , size_t Size, if_compatible_char< Char > = true>
constexpr static QAnyStringView fromArray (const Char(&string)[Size]) noexcept
 
static Q_CORE_EXPORT int compare (QAnyStringView lhs, QAnyStringView rhs, Qt::CaseSensitivity cs=Qt::CaseSensitive) noexcept
 
static Q_CORE_EXPORT bool equal (QAnyStringView lhs, QAnyStringView rhs) noexcept
 

Friends

bool operator== (QAnyStringView lhs, QAnyStringView rhs) noexcept
 
bool operator!= (QAnyStringView lhs, QAnyStringView rhs) noexcept
 
bool operator<= (QAnyStringView lhs, QAnyStringView rhs) noexcept
 
bool operator>= (QAnyStringView lhs, QAnyStringView rhs) noexcept
 
bool operator< (QAnyStringView lhs, QAnyStringView rhs) noexcept
 
bool operator> (QAnyStringView lhs, QAnyStringView rhs) noexcept
 

Detailed Description

Definition at line 55 of file qanystringview.h.

Member Typedef Documentation

◆ difference_type

Definition at line 58 of file qanystringview.h.

◆ size_type

Definition at line 59 of file qanystringview.h.

Constructor & Destructor Documentation

◆ QAnyStringView() [1/15]

constexpr QAnyStringView::QAnyStringView ( )
inlineconstexprnoexcept

Definition at line 132 of file qanystringview.h.

Here is the caller graph for this function:

◆ QAnyStringView() [2/15]

constexpr QAnyStringView::QAnyStringView ( std::nullptr_t  )
inlineconstexprnoexcept

Definition at line 134 of file qanystringview.h.

◆ QAnyStringView() [3/15]

template<typename Char , if_compatible_char< Char > = true>
constexpr QAnyStringView::QAnyStringView ( const Char str,
qsizetype  len 
)
inlineconstexpr

Definition at line 138 of file qanystringview.h.

◆ QAnyStringView() [4/15]

template<typename Char , if_compatible_char< Char > = true>
constexpr QAnyStringView::QAnyStringView ( const Char f,
const Char l 
)
inlineconstexpr

Definition at line 143 of file qanystringview.h.

◆ QAnyStringView() [5/15]

template<typename Pointer , if_compatible_pointer< Pointer > = true>
constexpr QAnyStringView::QAnyStringView ( const Pointer str)
inlineconstexprnoexcept

Definition at line 155 of file qanystringview.h.

◆ QAnyStringView() [6/15]

QAnyStringView::QAnyStringView ( const QByteArray str)
inlinenoexcept

Definition at line 1199 of file qstring.h.

Here is the call graph for this function:

◆ QAnyStringView() [7/15]

QAnyStringView::QAnyStringView ( const QString str)
inlinenoexcept

Definition at line 1201 of file qstring.h.

Here is the call graph for this function:

◆ QAnyStringView() [8/15]

constexpr QAnyStringView::QAnyStringView ( QLatin1String  str)
inlineconstexprnoexcept

Definition at line 353 of file qstring.h.

Here is the call graph for this function:

◆ QAnyStringView() [9/15]

template<typename A , typename B >
QAnyStringView::QAnyStringView ( const QStringBuilder< A, B > &  expr,
typename QConcatenable< QStringBuilder< A, B >>::ConvertTo &&  capacity = {} 
)
inline

Definition at line 496 of file qstringbuilder.h.

◆ QAnyStringView() [10/15]

template<typename Container , if_compatible_container< Container > = true>
constexpr QAnyStringView::QAnyStringView ( const Container c)
inlineconstexprnoexcept

Definition at line 170 of file qanystringview.h.

◆ QAnyStringView() [11/15]

template<typename Char , if_compatible_char< Char > = true>
constexpr QAnyStringView::QAnyStringView ( const Char c)
inlineconstexprnoexcept

Definition at line 174 of file qanystringview.h.

◆ QAnyStringView() [12/15]

constexpr QAnyStringView::QAnyStringView ( const QChar c)
inlineconstexprnoexcept

Definition at line 176 of file qanystringview.h.

◆ QAnyStringView() [13/15]

template<typename Char , typename Container = decltype(QChar::fromUcs4(U'x')), std::enable_if_t< std::is_same_v< Char, char32_t >, bool > = true>
constexpr QAnyStringView::QAnyStringView ( Char  c,
Container &&  capacity = {} 
)
inlineconstexpr

Definition at line 181 of file qanystringview.h.

◆ QAnyStringView() [14/15]

constexpr QAnyStringView::QAnyStringView ( QStringView  v)
inlineconstexprnoexcept

Definition at line 184 of file qanystringview.h.

◆ QAnyStringView() [15/15]

template<bool UseChar8T>
constexpr QAnyStringView::QAnyStringView ( QBasicUtf8StringView< UseChar8T >  v)
inlineconstexprnoexcept

Definition at line 188 of file qanystringview.h.

Member Function Documentation

◆ back()

constexpr QChar QAnyStringView::back ( ) const
constexpr

Definition at line 381 of file qstring.h.

◆ compare()

int QAnyStringView::compare ( QAnyStringView  lhs,
QAnyStringView  rhs,
Qt::CaseSensitivity  cs = Qt::CaseSensitive 
)
staticnoexcept

Definition at line 1636 of file qstring.cpp.

Here is the call graph for this function:

◆ data()

constexpr const void* QAnyStringView::data ( ) const
inlineconstexprnoexcept

Definition at line 202 of file qanystringview.h.

Here is the caller graph for this function:

◆ empty()

constexpr bool QAnyStringView::empty ( ) const
inlineconstexprnoexcept

Definition at line 212 of file qanystringview.h.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ equal()

bool QAnyStringView::equal ( QAnyStringView  lhs,
QAnyStringView  rhs 
)
staticnoexcept

Definition at line 1476 of file qstring.cpp.

Here is the call graph for this function:

◆ fromArray()

template<typename Char , size_t Size, if_compatible_char< Char > = true>
constexpr static QAnyStringView QAnyStringView::fromArray ( const Char(&)  string[Size])
inlinestaticconstexprnoexcept

Definition at line 192 of file qanystringview.h.

Here is the call graph for this function:

◆ front()

constexpr QChar QAnyStringView::front ( ) const
constexpr

Definition at line 377 of file qstring.h.

◆ isEmpty()

constexpr bool QAnyStringView::isEmpty ( ) const
inlineconstexprnoexcept

Definition at line 220 of file qanystringview.h.

Here is the call graph for this function:

◆ isNull()

constexpr bool QAnyStringView::isNull ( ) const
inlineconstexprnoexcept

Definition at line 219 of file qanystringview.h.

◆ length()

constexpr qsizetype QAnyStringView::length ( ) const
inlineconstexprnoexcept

Definition at line 221 of file qanystringview.h.

Here is the call graph for this function:

◆ size()

constexpr qsizetype QAnyStringView::size ( ) const
inlineconstexprnoexcept

Definition at line 201 of file qanystringview.h.

Here is the caller graph for this function:

◆ size_bytes()

constexpr qsizetype QAnyStringView::size_bytes ( ) const
inlineconstexprnoexcept

Definition at line 213 of file qanystringview.h.

Here is the call graph for this function:

◆ toString()

QString QAnyStringView::toString ( ) const
inline

Definition at line 1204 of file qstring.h.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ visit()

template<typename Visitor >
constexpr decltype(auto) QAnyStringView::visit ( Visitor &&  v) const
inlineconstexpr

Friends And Related Function Documentation

◆ operator!=

bool operator!= ( QAnyStringView  lhs,
QAnyStringView  rhs 
)
friend

Definition at line 227 of file qanystringview.h.

◆ operator<

bool operator< ( QAnyStringView  lhs,
QAnyStringView  rhs 
)
friend

Definition at line 238 of file qanystringview.h.

◆ operator<=

bool operator<= ( QAnyStringView  lhs,
QAnyStringView  rhs 
)
friend

Definition at line 234 of file qanystringview.h.

◆ operator==

bool operator== ( QAnyStringView  lhs,
QAnyStringView  rhs 
)
friend

Definition at line 225 of file qanystringview.h.

◆ operator>

bool operator> ( QAnyStringView  lhs,
QAnyStringView  rhs 
)
friend

Definition at line 240 of file qanystringview.h.

◆ operator>=

bool operator>= ( QAnyStringView  lhs,
QAnyStringView  rhs 
)
friend

Definition at line 236 of file qanystringview.h.

Member Data Documentation

◆ m_data

const void* QAnyStringView::m_data

Definition at line 284 of file qanystringview.h.

◆ m_data_utf16

const char16_t* QAnyStringView::m_data_utf16

Definition at line 286 of file qanystringview.h.

◆ m_data_utf8

const char* QAnyStringView::m_data_utf8

Definition at line 285 of file qanystringview.h.


The documentation for this class was generated from the following files: