|
|
|
IConnectionPointContainer Interface |
|
IID_IConnectionPointContainer |
{B196B284-BAB4-101A-B69C-00AA00341D07} |
|
The IConnectionPointContainer interface supports connection points for connectable objects.
Connectable objects support the following features:
Through IConnectionPointContainer, you can locate a specific connection point for one IID or obtain an enumerator to enumerate the connections points.
Use the IConnectionPointContainer interface to obtain access to:
|
|
Methods in VTable order |
|
|
IUnknown Methods |
Description |
|
QueryInterface |
Returns pointers to supported interfaces. |
|
AddRef |
Increments reference count. |
|
Release |
Decrements reference count. |
|
IConnectionPointContainer Methods |
Description |
|
EnumConnectionPoints |
Returns an object to enumerate all the connection points supported in the connectable object. |
|
FindConnectionPoint |
Returns a pointer to the IConnectionPoint interface for a specified connection point. |
|
QueryInterface |
|
FUNCTION IConectionPointContainer_QueryInterface ( _ BYVAL pthis AS DWORD PTR _ , BYREF riid AS GUID _ , BYREF ppvObj AS DWORD _ ) AS LONG
END FUNCTION
|
|
FUNCTION
IConectionPointContainer_QueryInterface ( _
|
|
AddRef |
|
FUNCTION IConnectionPointContainer_AddRef ( _ BYVAL pthis AS DWORD PTR _
)
AS DWORD
LOCAL DWRESULT
AS LONG END FUNCTION
|
|
FUNCTION IConnectionPointContainer_AddRef ( _ BYVAL pthis AS DWORD PTR _
)
AS DWORD
! mov eax, pthis END FUNCTION
|
|
Release |
|
FUNCTION IConnectionPoint_Release ( _ BYVAL pthis AS DWORD PTR _
)
AS DWORD
LOCAL DWRESULT
AS DWORD END FUNCTION
|
|
FUNCTION IConectionPointContainer_Release ( _ BYVAL pthis AS DWORD PTR _
)
AS DWORD
! mov eax, pthis END FUNCTION
|
|
IEnumConnectionPoints |
|
FUNCTION IConnectionPointContainer_EnumConnectionPoints ( _ BYVAL pthis AS DWORD PTR _ , BYREF ppenum AS DWORD _
)
AS LONG
|
|
FUNCTION IConnectionPointContainer_EnumConnectionPoints ( _ BYVAL pthis AS DWORD PTR _ , BYREF ppenum AS DWORD _ ) AS LONG
! push ppenum END FUNCTION
|
|
FindConnectionPoint |
|
FUNCTION IConnectionPointContainer_FindConnectionPoint ( _ BYVAL pthis AS DWORD PTR _ , BYREF riid AS GUID _ , BYREF ppCP AS DWORD _
) AS LONG
|
|
FUNCTION IConnectionPointContainer_FindConnectionPoint ( _ BYVAL pthis AS DWORD PTR _ , BYREF riid AS GUID _ , BYREF ppCP AS DWORD _
) AS LONG
! mov eax, riid
|
|
Example |
|
FUNCTION AtlAdvise ( _ BYVAL pUnkCP AS DWORD PTR _ , BYVAL pUnk AS DWORD _ , BYREF iid AS GUID _ , BYREF pdw AS DWORD _
) AS
LONG LOCAL pCP AS DWORD LOCAL IID_IConnectionPointContainer AS GUID IID_IConnectionPointContainer = GUID$("{B196B284-BAB4-101A-B69C-00AA00341D07}") IF punkCP = %NULL THEN FUNCTION = %E_INVALIDARG EXIT FUNCTION END IF hr = IUnknown_QueryInterface(pUnkCP, IID_IConnectionPointContainer, pCPC) IF SUCCEEDED(hr) THEN hr = IConnectionPointContainer_FindConnectionPoint(pCPC, iid, pCP) IF SUCCEEDED(hr) THEN hr = IConnectionPoint_Advise(pCP, pUnk, pdw) END IF
END IF |
Page last updated on Monday, 03 April 2006 20:24:49 +0200