_com_ptr_t::_com_ptr_t

Microsoft Specific

_com_ptr_t( ) throw( );

_com_ptr_t( Interface* pInterface ) throw( );

_com_ptr_t( Interface* pInterface, bool fAddRef ) throw( );

_com_ptr_t( int NULL ) throw( _com_error );

template< > _com_ptr_t( const _com_ptr_t& cp ) throw( );

template<typename _InterfacePtr> _com_ptr_t( const _InterfacePtr& p ) throw( _com_error );

template< > _com_ptr_t( const _variant_t& varSrc ) throw( _com_error );

explicit _com_ptr_t( const CLSID& clsid, DWORD dwClsContext = CLSCTX_ALL) throw( _com_error );

explicit _com_ptr_t( LPOLESTR lpOleStr, DWORD dwClsContext = CLSCTX_ALL) throw( _com_error );

explicit _com_ptr_t( LPCSTR lpcStr, DWORD dwClsContext = CLSCTX_ALL ) throw( _com_error );

Parameters

pInterface

a raw interface pointer

fAddRef

if true, AddRef is called to increment the reference count of the encapsulated interface pointer

cp

a _com_ptr_t object

p

a raw interface pointer, its type being different from the smart pointer type of this _com_ptr_t object

varSrc

a _variant_t object

clsid

the CLSID of a coclass

dwClsContext

context for running executable code

lpOleStr

a Unicode string that holds either a CLSID (starting with “{“) or a ProgID

lpcStr

a multibyte string that holds either a CLSID (starting with “{“) or a ProgID.

Remarks

Constructs a _com_ptr_t object.

_com_ptr_t Overview

END Microsoft Specific