Export (0) Print
Expand All

IConnectionPointContainer::EnumConnectionPoints method

Creates an enumerator object to iterate through all the connection points supported in the connectable object, one connection point per outgoing IID.

Syntax


HRESULT EnumConnectionPoints(
  [out]  IEnumConnectionPoints **ppEnum
);

Parameters

ppEnum [out]

A pointer to an IEnumConnectionPoints interface pointer variable that receives the pointer to the newly created enumerator.

Return value

This method can return the standard return values E_OUTOFMEMORY and E_UNEXPECTED, as well as the following values.

Return codeDescription
S_OK

The enumerator object was created successfully.

E_POINTER

The address in ppEnum is not valid. For example, it may be NULL.

 

Remarks

Because IEnumConnectionPoints enumerates pointers to IConnectionPoint, the caller must use IConnectionPoint::GetConnectionInterface to determine the interface identifier of the outgoing interface that the connection point supports.

Notes to Callers

The caller is responsible for calling Release when the enumerator is no longer needed.

Notes to Implementers

Returning E_NOTIMPL is specifically disallowed because, with the exception of type information, there would be no other means through which a caller could find the IIDs of the outgoing interfaces. Since a connectable object typically has a fixed set of known outgoing interfaces, it is straightforward to implement the enumerator on top of a fixed length array of IIDs known at compile time.

Requirements

Minimum supported client

Windows 2000 Professional [desktop apps | Windows Store apps]

Minimum supported server

Windows 2000 Server [desktop apps | Windows Store apps]

Header

OCIdl.h

IDL

OCIdl.idl

IID

IID_IConnectionPointContainer is defined as B196B284-BAB4-101A-B69C-00AA00341D07

See also

IConnectionPointContainer
IEnumConnectionPoints

 

 

Community Additions

ADD
Show:
© 2015 Microsoft