Basic< T > Class Template Reference

#include <qsharedpointer_impl.h>

Class Description

template<class T>
class QtSharedPointer::Basic< T >

Definition at line 131 of file qsharedpointer_impl.h.

+ Inheritance diagram for Basic< T >:

Public Types

typedef T Type
 
typedef T element_type
 
typedef T value_type
 
typedef value_typepointer
 
typedef const value_typeconst_pointer
 
typedef value_typereference
 
typedef const value_typeconst_reference
 
typedef qptrdiff difference_type
 

Public Member Functions

T * data () const
 
bool isNull () const
 
 operator RestrictedBool () const
 
bool operator! () const
 
T & operator* () const
 
T * operator-> () const
 

Protected Member Functions

 Basic (T *ptr=0)
 
 Basic (Qt::Initialization)
 
void internalConstruct (T *ptr)
 

Protected Attributes

Typevalue
 

Friends

template<class X >
class QT_PREPEND_NAMESPACE (QWeakPointer)
 

Member Typedef Documentation

typedef T Type

Definition at line 137 of file qsharedpointer_impl.h.

typedef T element_type

Definition at line 138 of file qsharedpointer_impl.h.

typedef T value_type

Definition at line 139 of file qsharedpointer_impl.h.

typedef value_type* pointer

Definition at line 140 of file qsharedpointer_impl.h.

typedef const value_type* const_pointer

Definition at line 141 of file qsharedpointer_impl.h.

Definition at line 142 of file qsharedpointer_impl.h.

typedef const value_type& const_reference

Definition at line 143 of file qsharedpointer_impl.h.

typedef qptrdiff difference_type

Definition at line 144 of file qsharedpointer_impl.h.

Constructor & Destructor Documentation

Basic ( T *  ptr = 0)
inlineprotected

Definition at line 158 of file qsharedpointer_impl.h.

158 : value(ptr) { }
Basic ( Qt::Initialization  )
inlineprotected

Definition at line 159 of file qsharedpointer_impl.h.

159 { }

Member Function Documentation

T* data ( ) const
inline

Definition at line 146 of file qsharedpointer_impl.h.

146 { return value; }
bool isNull ( ) const
inline

Definition at line 147 of file qsharedpointer_impl.h.

147 { return !data(); }
operator RestrictedBool ( ) const
inline

Definition at line 149 of file qsharedpointer_impl.h.

149 { return isNull() ? 0 : &Basic::value; }
bool operator! ( void  ) const
inline

Definition at line 153 of file qsharedpointer_impl.h.

153 { return isNull(); }
T& operator* ( ) const
inline

Definition at line 154 of file qsharedpointer_impl.h.

154 { return *data(); }
T* operator-> ( void  ) const
inline

Definition at line 155 of file qsharedpointer_impl.h.

155 { return data(); }
void internalConstruct ( T *  ptr)
inlineprotected

Definition at line 162 of file qsharedpointer_impl.h.

163  {
164  value = ptr;
165  }
GLsizei const GLfloat * value
Definition: GLee.h:1742

Friends And Related Function Documentation

class QT_PREPEND_NAMESPACE ( QWeakPointer  )
friend

Member Data Documentation

Type* value
protected

Definition at line 173 of file qsharedpointer_impl.h.


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