QObject Smart pointer which create an object and synchronize its life time. //! More...
#include <objectptr.hpp>
Classes | |
struct | interptr |
struct | interptr< false, TPTR > |
struct | interptr< true, TPTR > |
struct | myPtr |
Public Member Functions | |
template<typename P1 , typename P2 , typename P3 , typename P4 , typename P5 > | |
ObjectPtr (const P1 &p1, const P2 &p2, const P3 &p3, const P4 &p4, const P5 &p5) | |
Smart pointer Constructor. //! | |
template<typename P1 , typename P2 , typename P3 , typename P4 > | |
ObjectPtr (const P1 &p1, const P2 &p2, const P3 &p3, const P4 &p4) | |
Smart pointer Constructor. //! | |
template<typename P1 , typename P2 , typename P3 > | |
ObjectPtr (const P1 &p1, const P2 &p2, const P3 &p3) | |
Smart pointer Constructor. //! | |
template<typename P1 , typename P2 > | |
ObjectPtr (const P1 &p1, const P2 &p2) | |
Smart pointer Constructor. //! | |
template<typename P > | |
ObjectPtr (const P &p) | |
Smart pointer Constructor. //! | |
ObjectPtr () | |
Smart pointer Constructor. //! | |
~ObjectPtr () | |
Smart pointer Destructor. Use DeletePolicy to decide if object should be deleted. //! | |
bool | isNull () const |
Test if the pointer is null. //! | |
operator bool () const | |
Bool convertion. It's true if object is not destroyed (Parent destruction). //! | |
operator T * () | |
Cast to the object pointer. //! | |
operator const T * () const | |
Cast to the const object pointer. //! | |
T * | operator-> () |
Indirection Operator. //! | |
const T * | operator-> () const |
Indirection Operator. //! | |
T & | operator* () |
Indirection Operator. //! | |
const T & | operator* () const |
Indirection Operator. //! |
QObject Smart pointer which create an object and synchronize its life time. //!
ObjectPtr is use to create automatically the object. Proposed features are :
T | QObject type. | |
DeletePolicy | delete object policy used. Defaut is SCOPE policy. |
Definition at line 68 of file objectptr.hpp.
QExtend::ObjectPtr< T, DeletePolicy >::ObjectPtr | ( | const P1 & | p1, | |
const P2 & | p2, | |||
const P3 & | p3, | |||
const P4 & | p4, | |||
const P5 & | p5 | |||
) | [inline] |
Smart pointer Constructor. //!
Create Object with five parameters. Parameters types are defined by compilator.
P1 | First parameter type. | |
P2 | Second parameter type. | |
P3 | Third parameter type. | |
P4 | fourth parameter type. | |
P5 | fifth parameter type. |
p1 | First parameter. | |
p2 | Second parameter. | |
p3 | Third parameter. | |
p4 | fourth parameter. | |
p5 | fifth parameter. |
Definition at line 161 of file objectptr.hpp.
QExtend::ObjectPtr< T, DeletePolicy >::ObjectPtr | ( | const P1 & | p1, | |
const P2 & | p2, | |||
const P3 & | p3, | |||
const P4 & | p4 | |||
) | [inline] |
Smart pointer Constructor. //!
Create Object with four parameters. Parameters types are defined by compilator.
P1 | First parameter type. | |
P2 | Second parameter type. | |
P3 | Third parameter type. | |
P4 | fourth parameter type. |
p1 | First parameter. | |
p2 | Second parameter. | |
p3 | Third parameter. | |
p4 | fourth parameter. |
Definition at line 216 of file objectptr.hpp.
QExtend::ObjectPtr< T, DeletePolicy >::ObjectPtr | ( | const P1 & | p1, | |
const P2 & | p2, | |||
const P3 & | p3 | |||
) | [inline] |
Smart pointer Constructor. //!
Create Object with three parameters. Parameters types are defined by compilator.
P1 | First parameter type. | |
P2 | Second parameter type. | |
P3 | Third parameter type. |
p1 | First parameter. | |
p2 | Second parameter. | |
p3 | Third parameter. |
Definition at line 265 of file objectptr.hpp.
QExtend::ObjectPtr< T, DeletePolicy >::ObjectPtr | ( | const P1 & | p1, | |
const P2 & | p2 | |||
) | [inline] |
Smart pointer Constructor. //!
Create Object with two parameters. Parameters types are defined by compilator.
P1 | First parameter type. | |
P2 | Second parameter type. |
p1 | First parameter. | |
p2 | Second parameter. |
Definition at line 303 of file objectptr.hpp.
QExtend::ObjectPtr< T, DeletePolicy >::ObjectPtr | ( | const P & | p | ) | [inline] |
Smart pointer Constructor. //!
Create Object with a parameter. Parameter type is defined by compilator.
P | parameter type. |
p | parametre. |
Definition at line 334 of file objectptr.hpp.
QExtend::ObjectPtr< T, DeletePolicy >::ObjectPtr | ( | ) | [inline] |
Smart pointer Constructor. //!
Create Object with its default constructor.
Definition at line 353 of file objectptr.hpp.
QExtend::ObjectPtr< T, DeletePolicy >::~ObjectPtr | ( | ) | [inline] |
Smart pointer Destructor. Use DeletePolicy to decide if object should be deleted. //!
Delete Object.
Definition at line 373 of file objectptr.hpp.
bool QExtend::ObjectPtr< T, DeletePolicy >::isNull | ( | ) | const [inline] |
Test if the pointer is null. //!
Definition at line 393 of file objectptr.hpp.
QExtend::ObjectPtr< T, DeletePolicy >::operator bool | ( | ) | const [inline] |
Bool convertion. It's true if object is not destroyed (Parent destruction). //!
Definition at line 400 of file objectptr.hpp.
QExtend::ObjectPtr< T, DeletePolicy >::operator const T * | ( | ) | const [inline] |
Cast to the const object pointer. //!
Definition at line 414 of file objectptr.hpp.
QExtend::ObjectPtr< T, DeletePolicy >::operator T * | ( | ) | [inline] |
Cast to the object pointer. //!
Definition at line 407 of file objectptr.hpp.
T& QExtend::ObjectPtr< T, DeletePolicy >::operator* | ( | ) | [inline] |
Indirection Operator. //!
Definition at line 462 of file objectptr.hpp.
const T& QExtend::ObjectPtr< T, DeletePolicy >::operator* | ( | ) | const [inline] |
Indirection Operator. //!
Definition at line 477 of file objectptr.hpp.
const T* QExtend::ObjectPtr< T, DeletePolicy >::operator-> | ( | ) | const [inline] |
Indirection Operator. //!
Definition at line 446 of file objectptr.hpp.
T* QExtend::ObjectPtr< T, DeletePolicy >::operator-> | ( | ) | [inline] |
Indirection Operator. //!
Definition at line 431 of file objectptr.hpp.
Les sources présentées sur cette page sont libres de droits et vous pouvez les utiliser à votre convenance. Par contre, la page de présentation constitue une œuvre intellectuelle protégée par les droits d'auteur. Copyright © 2010 Developpez LLC. Tous droits réservés Developpez LLC. Aucune reproduction, même partielle, ne peut être faite de ce site ni de l'ensemble de son contenu : textes, documents et images sans l'autorisation expresse de Developpez LLC. Sinon vous encourez selon la loi jusqu'à trois ans de prison et jusqu'à 300 000 € de dommages et intérêts.