CComObject Class

此选件类实现一nonaggregated对象的 IUnknown

template< 
   class Base  
> 
class CComObject : 
   public Base

参数

成员

公共构造函数

名称

说明

CComObject::CComObject

构造函数。

CComObject::~CComObject

该析构函数。

公共方法

名称

说明

CComObject::AddRef

递增对象的引用计数。

CComObject::CreateInstance

(静态)创建新的 CComObject 对象。

CComObject::QueryInterface

检索指向请求的接口。

CComObject::Release

在递减对象的引用计数。

备注

一nonaggregated对象的CComObject 实现 IUnknown。 但是,对 QueryInterfaceAddRef,并且,Release 将委托给 CComObjectRootEx

有关使用 CComObject的更多信息,请参见文章 ATL COM对象的基本知识

继承层次结构

Base

CComObject

要求

Header: atlcom.h

请参见

参考

CComAggObject Class

CComPolyObject Class

DECLARE_AGGREGATABLE

DECLARE_NOT_AGGREGATABLE

其他资源

ATL Class Overview