Otclient  14/8/2020
stdext::shared_ptr< T > Class Template Reference

#include <shared_ptr.h>

Public Types

typedef T element_type
 
typedef shared_base< T > *shared_ptr::* unspecified_bool_type
 

Public Member Functions

 shared_ptr ()
 
 shared_ptr (T *p)
 
 shared_ptr (shared_ptr const &rhs)
 
template<class U >
 shared_ptr (shared_ptr< U > const &rhs, typename std::is_convertible< U, T >::type *=nullptr)
 
 ~shared_ptr ()
 
void reset ()
 
void reset (T *rhs)
 
void swap (shared_ptr &rhs)
 
void set (T *p)
 
T * get () const
 
refcount_t use_count () const
 
refcount_t weak_count () const
 
bool is_unique () const
 
T & operator* () const
 
T * operator-> () const
 
template<class U >
shared_ptroperator= (shared_ptr< U > const &rhs)
 
shared_ptroperator= (shared_ptr const &rhs)
 
shared_ptroperator= (T *rhs)
 
 operator unspecified_bool_type () const
 
bool operator! () const
 
 shared_ptr (shared_ptr &&rhs)
 
shared_ptroperator= (shared_ptr &&rhs)
 

Friends

class weak_ptr< T >
 

Detailed Description

template<class T>
class stdext::shared_ptr< T >

Definition at line 40 of file shared_ptr.h.

Member Typedef Documentation

◆ element_type

template<class T >
typedef T stdext::shared_ptr< T >::element_type

Definition at line 96 of file shared_ptr.h.

◆ unspecified_bool_type

template<class T >
typedef shared_base<T>* shared_ptr::* stdext::shared_ptr< T >::unspecified_bool_type

Definition at line 125 of file shared_ptr.h.

Constructor & Destructor Documentation

◆ shared_ptr() [1/5]

template<class T >
stdext::shared_ptr< T >::shared_ptr ( )
inline

Definition at line 98 of file shared_ptr.h.

Here is the caller graph for this function:

◆ shared_ptr() [2/5]

template<class T >
stdext::shared_ptr< T >::shared_ptr ( T *  p)
inline

Definition at line 99 of file shared_ptr.h.

◆ shared_ptr() [3/5]

template<class T >
stdext::shared_ptr< T >::shared_ptr ( shared_ptr< T > const &  rhs)
inline

Definition at line 100 of file shared_ptr.h.

◆ shared_ptr() [4/5]

template<class T >
template<class U >
stdext::shared_ptr< T >::shared_ptr ( shared_ptr< U > const &  rhs,
typename std::is_convertible< U, T >::type *  = nullptr 
)
inline

Definition at line 102 of file shared_ptr.h.

◆ ~shared_ptr()

template<class T >
stdext::shared_ptr< T >::~shared_ptr ( )
inline

Definition at line 103 of file shared_ptr.h.

◆ shared_ptr() [5/5]

template<class T >
stdext::shared_ptr< T >::shared_ptr ( shared_ptr< T > &&  rhs)
inline

Definition at line 130 of file shared_ptr.h.

Member Function Documentation

◆ get()

template<class T >
T* stdext::shared_ptr< T >::get ( ) const
inline

Definition at line 110 of file shared_ptr.h.

Here is the caller graph for this function:

◆ is_unique()

template<class T >
bool stdext::shared_ptr< T >::is_unique ( ) const
inline

Definition at line 114 of file shared_ptr.h.

Here is the call graph for this function:

◆ operator unspecified_bool_type()

template<class T >
stdext::shared_ptr< T >::operator unspecified_bool_type ( ) const
inline

Definition at line 126 of file shared_ptr.h.

◆ operator!()

template<class T >
bool stdext::shared_ptr< T >::operator! ( ) const
inline

Definition at line 127 of file shared_ptr.h.

◆ operator*()

template<class T >
T& stdext::shared_ptr< T >::operator* ( ) const
inline

Definition at line 116 of file shared_ptr.h.

◆ operator->()

template<class T >
T* stdext::shared_ptr< T >::operator-> ( ) const
inline

Definition at line 117 of file shared_ptr.h.

◆ operator=() [1/4]

template<class T >
shared_ptr& stdext::shared_ptr< T >::operator= ( shared_ptr< T > &&  rhs)
inline

Definition at line 131 of file shared_ptr.h.

Here is the call graph for this function:

◆ operator=() [2/4]

template<class T >
shared_ptr& stdext::shared_ptr< T >::operator= ( shared_ptr< T > const &  rhs)
inline

Definition at line 121 of file shared_ptr.h.

Here is the call graph for this function:

◆ operator=() [3/4]

template<class T >
template<class U >
shared_ptr& stdext::shared_ptr< T >::operator= ( shared_ptr< U > const &  rhs)
inline

Definition at line 120 of file shared_ptr.h.

Here is the call graph for this function:

◆ operator=() [4/4]

template<class T >
shared_ptr& stdext::shared_ptr< T >::operator= ( T *  rhs)
inline

Definition at line 122 of file shared_ptr.h.

Here is the call graph for this function:

◆ reset() [1/2]

template<class T >
void stdext::shared_ptr< T >::reset ( )
inline

Definition at line 105 of file shared_ptr.h.

Here is the call graph for this function:

◆ reset() [2/2]

template<class T >
void stdext::shared_ptr< T >::reset ( T *  rhs)
inline

Definition at line 106 of file shared_ptr.h.

Here is the call graph for this function:

◆ set()

template<class T >
void stdext::shared_ptr< T >::set ( T *  p)
inline

Definition at line 109 of file shared_ptr.h.

◆ swap()

template<class T >
void stdext::shared_ptr< T >::swap ( shared_ptr< T > &  rhs)
inline

Definition at line 107 of file shared_ptr.h.

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

◆ use_count()

template<class T >
refcount_t stdext::shared_ptr< T >::use_count ( ) const
inline

Definition at line 112 of file shared_ptr.h.

Here is the caller graph for this function:

◆ weak_count()

template<class T >
refcount_t stdext::shared_ptr< T >::weak_count ( ) const
inline

Definition at line 113 of file shared_ptr.h.

Friends And Related Function Documentation

◆ weak_ptr< T >

template<class T >
friend class weak_ptr< T >
friend

Definition at line 143 of file shared_ptr.h.


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