Share via


WSACOMPLETION (Windows Embedded CE 6.0)

1/6/2010

This structure specifies completion notification settings for I/O control calls made to a registered namespace.

Syntax

typedef struct _WSACOMPLETION {
    WSACOMPLETIONTYPE Type;
    union {
        struct {
            HWND hWnd;
            UINT uMsg;
            WPARAM context;
        } WindowMessage;
        struct {
            LPWSAOVERLAPPED lpOverlapped;
        } Event;
        struct {
            LPWSAOVERLAPPED lpOverlapped;
            LPWSAOVERLAPPED_COMPLETION_ROUTINE lpfnCompletionProc;
        } Apc;
        struct {
            LPWSAOVERLAPPED lpOverlapped;
            HANDLE hPort;
            ULONG_PTR Key;
        } Port;
    } Parameters;
} WSACOMPLETION, *PWSACOMPLETION, FAR *LPWSACOMPLETION;

Members

  • Type
    Type of completion notification required. See Remarks.
  • Parameters
    Parameters required to complete the callback. The structures within the Parameters union, specify information required for completing the callback of each given type. WindowMessage(This structure must be filled when Type is set to NSP_NOTIFY_HWND)
  • hWnd
    Windows handle uMsg

    Message handle context

    Context of the message or handle Event

  • lpOverlapped
    Pointer to a WSAOVERLAPPED structure. lpfnCompletionProc

    Pointer to an application-provided completion routine Port

  • lpOverlapped
    Pointer to a WSAOVERLAPPED structure. hPort

    Handle to the port Key

    Pointer to the key Remarks

This structure enables callbacks to be provided in any of the following formats, based on the value provided in Type:

Callback format Type value

Polling

NSP_NOTIFY_IMMEDIATELY

Window Message

NSP_NOTIFY_HWND

Event

NSP_NOTIFY_EVENT

APC

NSP_NOTIFY_APC

Completion Port

NSP_NOTIFY_PORT

For a blocking function, set this structure to null.

Requirements

Header winsock2.h
Windows Embedded CE Windows CE .NET 4.0 and later

See Also

Reference

Winsock Structures
WSANSPIoctl

Other Resources

Windows Sockets