COM_INTERFACE_ENTRY_AUTOAGGREGATE
TOC
Collapse the table of content
Expand the table of content
Important This document may not represent best practices for current development, links to downloads and other resources may no longer be valid. Current recommended version can be found here. ArchiveDisclaimer

COM_INTERFACE_ENTRY_AUTOAGGREGATE

Same as COM_INTERFACE_ENTRY_AGGREGATE, except if punk is NULL, it automatically creates the aggregate described by the clsid.

COM_INTERFACE_ENTRY_AUTOAGGREGATE( iid, punk, clsid )

Parameters

iid
[in] The GUID of the interface queried for.
punk
[in] The name of an IUnknown pointer. Must be a member of the class containing the COM map.
clsid
[in] The identifier of the aggregate that will be created if punk is NULL.

Remarks

See COM_INTERFACE_ENTRY Macros for remarks about COM map entries.

Example

From the ATL sample COMMAP:

BEGIN_COM_MAP(COuter)
...
   COM_INTERFACE_ENTRY_AUTOAGGREGATE(IID_IAutoAgg, m_pUnkAutoAgg.p, CLSID_CAutoAgg)
...
END_COM_MAP()

See Also

COM Map Macros | ATL Macros

Show:
© 2016 Microsoft