Freigeben über


CComQIPtr Class

A smart pointer class for managing COM interface pointers.

template< 
   class T, 
   const IID* piid = &__uuidof(T) 
> 
class CComQIPtr: public CComPtr<T>

Parameters

  • T
    A COM interface specifying the type of pointer to be stored.

  • piid
    A pointer to the IID of T.

Members

Public Constructors

Name

Description

CComQIPtr::CComQIPtr

Constructor.

Public Operators

Name

Description

CComQIPtr::operator =

Assigns a pointer to the member pointer.

Remarks

ATL uses CComQIPtr and CComPtr to manage COM interface pointers, both of which derive from CComPtrBase. Both classes perform automatic reference counting through calls to AddRef and Release. Overloaded operators handle pointer operations.

Inheritance Hierarchy

CComPtrBase

CComPtr

CComQIPtr

Requirements

Header: atlcomcli.h

See Also

Reference

CComPtr::CComPtr

CComQIPtr::CComQIPtr

CComPtrBase Class

CComQIPtrElementTraits Class

Other Resources

ATL Class Overview