Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
Loading...
Searching...
No Matches
QSharedDataPointerBase< P, T > Class Template Reference

#include <qshareddata.h>

Inheritance diagram for QSharedDataPointerBase< P, T >:
Collaboration diagram for QSharedDataPointerBase< P, T >:

Public Types

using Type = T
using pointer = T *

Public Member Functions

void detach ()
T & operator* ()
constT & operator* () const
T * operator-> ()
constT * operator-> () const noexcept
 operator T* ()
 operator const T * () const noexcept
T * data ()
T * get ()
const T * data () const noexcept
const T * get () const noexcept
const T * constData () const noexcept
T * take () noexcept
void reset (T *ptr=nullptr) noexcept
 operator bool () const noexcept
bool operator! () const noexcept
void swap (Self &other) noexcept

Protected Member Functions

constexpr QSharedDataPointerBase (T *ptr=nullptr) noexcept
void detach_helper ()

Protected Attributes

Qt::totally_ordered_wrapper< T * > d

Friends

bool comparesEqual (const QSharedDataPointerBase &lhs, const QSharedDataPointerBase &rhs) noexcept
Qt::strong_ordering compareThreeWay (const QSharedDataPointerBase &lhs, const QSharedDataPointerBase &rhs) noexcept
bool comparesEqual (const QSharedDataPointerBase &lhs, const T *rhs) noexcept
Qt::strong_ordering compareThreeWay (const QSharedDataPointerBase &lhs, const T *rhs) noexcept
bool comparesEqual (const QSharedDataPointerBase &lhs, std::nullptr_t) noexcept
Qt::strong_ordering compareThreeWay (const QSharedDataPointerBase &lhs, std::nullptr_t) noexcept
size_t qHash (const QSharedDataPointerBase &ptr, size_t seed=0) noexcept

Detailed Description

template<template< typename > class P, typename T>
class QSharedDataPointerBase< P, T >

Definition at line 53 of file qshareddata.h.

Member Typedef Documentation

◆ pointer

template<template< typename > class P, typename T>
using QSharedDataPointerBase< P, T >::pointer = T *

Definition at line 68 of file qshareddata.h.

◆ Type

template<template< typename > class P, typename T>
using QSharedDataPointerBase< P, T >::Type = T

Definition at line 67 of file qshareddata.h.

Constructor & Destructor Documentation

◆ QSharedDataPointerBase()

template<template< typename > class P, typename T>
QSharedDataPointerBase< P, T >::QSharedDataPointerBase ( T * ptr = nullptr)
inlineconstexprprotectednoexcept

Definition at line 61 of file qshareddata.h.

Referenced by QSharedDataPointerBase< QSharedDataPointer, T >::QSharedDataPointerBase().

Here is the caller graph for this function:

Member Function Documentation

◆ constData()

template<template< typename > class P, typename T>
const T * QSharedDataPointerBase< P, T >::constData ( ) const
inlinenoexcept

Definition at line 81 of file qshareddata.h.

◆ data() [1/2]

template<template< typename > class P, typename T>
T * QSharedDataPointerBase< P, T >::data ( )
inline

Definition at line 77 of file qshareddata.h.

◆ data() [2/2]

template<template< typename > class P, typename T>
const T * QSharedDataPointerBase< P, T >::data ( ) const
inlinenoexcept

Definition at line 79 of file qshareddata.h.

◆ detach()

template<template< typename > class P, typename T>
void QSharedDataPointerBase< P, T >::detach ( )
inline

Definition at line 70 of file qshareddata.h.

◆ detach_helper()

template<template< typename > class P, typename T>
Q_OUTOFLINE_TEMPLATE void QSharedDataPointerBase< P, T >::detach_helper ( )
protected

Definition at line 334 of file qshareddata.h.

Referenced by QSharedDataPointerBase< QSharedDataPointer, T >::detach().

Here is the caller graph for this function:

◆ get() [1/2]

template<template< typename > class P, typename T>
T * QSharedDataPointerBase< P, T >::get ( )
inline

Definition at line 78 of file qshareddata.h.

◆ get() [2/2]

template<template< typename > class P, typename T>
const T * QSharedDataPointerBase< P, T >::get ( ) const
inlinenoexcept

Definition at line 80 of file qshareddata.h.

◆ operator bool()

template<template< typename > class P, typename T>
QSharedDataPointerBase< P, T >::operator bool ( ) const
inlinenoexcept

Definition at line 95 of file qshareddata.h.

◆ operator const T *()

template<template< typename > class P, typename T>
QSharedDataPointerBase< P, T >::operator const T * ( ) const
inlinenoexcept

Definition at line 76 of file qshareddata.h.

◆ operator T*()

template<template< typename > class P, typename T>
QSharedDataPointerBase< P, T >::operator T* ( )
inline

Definition at line 75 of file qshareddata.h.

◆ operator!()

template<template< typename > class P, typename T>
bool QSharedDataPointerBase< P, T >::operator! ( ) const
inlinenoexcept

Definition at line 96 of file qshareddata.h.

◆ operator*() [1/2]

template<template< typename > class P, typename T>
T & QSharedDataPointerBase< P, T >::operator* ( )
inline

Definition at line 71 of file qshareddata.h.

◆ operator*() [2/2]

template<template< typename > class P, typename T>
constT & QSharedDataPointerBase< P, T >::operator* ( ) const
inline

Definition at line 72 of file qshareddata.h.

◆ operator->() [1/2]

template<template< typename > class P, typename T>
T * QSharedDataPointerBase< P, T >::operator-> ( )
inline

Definition at line 73 of file qshareddata.h.

◆ operator->() [2/2]

template<template< typename > class P, typename T>
constT * QSharedDataPointerBase< P, T >::operator-> ( ) const
inlinenoexcept

Definition at line 74 of file qshareddata.h.

◆ reset()

template<template< typename > class P, typename T>
void QSharedDataPointerBase< P, T >::reset ( T * ptr = nullptr)
inlinenoexcept

Definition at line 84 of file qshareddata.h.

◆ swap()

template<template< typename > class P, typename T>
void QSharedDataPointerBase< P, T >::swap ( Self & other)
inlinenoexcept

Definition at line 98 of file qshareddata.h.

◆ take()

template<template< typename > class P, typename T>
T * QSharedDataPointerBase< P, T >::take ( )
inlinenoexcept

Definition at line 82 of file qshareddata.h.

◆ comparesEqual [1/3]

template<template< typename > class P, typename T>
bool comparesEqual ( const QSharedDataPointerBase< P, T > & lhs,
const QSharedDataPointerBase< P, T > & rhs )
friend

Definition at line 115 of file qshareddata.h.

◆ comparesEqual [2/3]

template<template< typename > class P, typename T>
bool comparesEqual ( const QSharedDataPointerBase< P, T > & lhs,
const T * rhs )
friend

Definition at line 121 of file qshareddata.h.

◆ comparesEqual [3/3]

template<template< typename > class P, typename T>
bool comparesEqual ( const QSharedDataPointerBase< P, T > & lhs,
std::nullptr_t  )
friend

Definition at line 127 of file qshareddata.h.

◆ compareThreeWay [1/3]

template<template< typename > class P, typename T>
Qt::strong_ordering compareThreeWay ( const QSharedDataPointerBase< P, T > & lhs,
const QSharedDataPointerBase< P, T > & rhs )
friend

Definition at line 118 of file qshareddata.h.

◆ compareThreeWay [2/3]

template<template< typename > class P, typename T>
Qt::strong_ordering compareThreeWay ( const QSharedDataPointerBase< P, T > & lhs,
const T * rhs )
friend

Definition at line 124 of file qshareddata.h.

◆ compareThreeWay [3/3]

template<template< typename > class P, typename T>
Qt::strong_ordering compareThreeWay ( const QSharedDataPointerBase< P, T > & lhs,
std::nullptr_t  )
friend

Definition at line 130 of file qshareddata.h.

◆ qHash

template<template< typename > class P, typename T>
size_t qHash ( const QSharedDataPointerBase< P, T > & ptr,
size_t seed = 0 )
friend

Definition at line 133 of file qshareddata.h.

Member Data Documentation

◆ d

template<template< typename > class P, typename T>
Qt::totally_ordered_wrapper<T *> QSharedDataPointerBase< P, T >::d
protected

Definition at line 139 of file qshareddata.h.


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