CComContainedObject Class
This class implements IUnknown by delegating to the owner object's IUnknown.
Important
This class and its members cannot be used in applications that execute in the Windows Runtime.
template<
class Base
>
class CComContainedObject :
public Base
Parameters
- Base
Your class, derived from CComObjectRoot or CComObjectRootEx.
Members
Public Constructors
Name |
Description |
---|---|
The constructor. Initializes the member pointer to the owner object's IUnknown. |
|
The destructor. |
Public Methods
Name |
Description |
---|---|
Increments the reference count on the owner object. |
|
Retrieves the owner object's IUnknown. |
|
Retrieves a pointer to the interface requested on the owner object. |
|
Decrements the reference count on the owner object. |
Remarks
ATL uses CComContainedObject in classes CComAggObject, CComPolyObject, and CComCachedTearOffObject. CComContainedObject implements IUnknown by delegating to the owner object's IUnknown. (The owner is either the outer object of an aggregation, or the object for which a tear-off interface is being created.) CComContainedObject calls CComObjectRootEx's OuterQueryInterface, OuterAddRef, and OuterRelease, all inherited through Base.
Inheritance Hierarchy
Base
CComContainedObject
Requirements
Header: atlcom.h