Qpid Management Framework  0.22
qmf::Handle Class Reference

#include <Handle.h>

List of all members.

Public Member Functions

QMF_INLINE_EXTERN bool isValid () const
QMF_INLINE_EXTERN bool isNull () const
QMF_INLINE_EXTERN operator bool () const
QMF_INLINE_EXTERN bool operator! () const
void swap (Handle< T > &h)

Protected Types

typedef T Impl

Protected Member Functions

QMF_EXTERN Handle (const Handle &)
QMF_EXTERN Handleoperator= (const Handle &)

Protected Attributes



class PrivateImplRef< T >

Detailed Description

A handle is like a pointer: refers to an underlying implementation object. Copying the handle does not copy the object.

Handles can be null, like a 0 pointer. Use isValid(), isNull() or the conversion to bool to test for a null handle.

Member Typedef Documentation

typedef T qmf::Handle::Impl [protected]

Constructor & Destructor Documentation

QMF_INLINE_EXTERN qmf::Handle::Handle ( ) [inline, protected]
QMF_EXTERN qmf::Handle::Handle ( const Handle ) [protected]

Member Function Documentation

QMF_INLINE_EXTERN bool qmf::Handle::isNull ( ) const [inline]
true if handle is null. It is an error to call any function on a null handle.
QMF_INLINE_EXTERN bool qmf::Handle::isValid ( ) const [inline]
true if handle is valid, i.e. not null.
QMF_INLINE_EXTERN qmf::Handle::operator bool ( ) const [inline]

Conversion to bool supports idiom if (handle) { handle->... }

QMF_INLINE_EXTERN bool qmf::Handle::operator! ( ) const [inline]

Operator ! supports idiom if (!handle) { do_if_handle_is_null(); }

QMF_EXTERN Handle& qmf::Handle::operator= ( const Handle ) [protected]
void qmf::Handle::swap ( Handle< T > &  h) [inline]

Friends And Related Function Documentation

friend class PrivateImplRef< T > [friend]

Member Data Documentation

Impl* qmf::Handle::impl [protected]

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