Share via


Windows-Specific Extension Functions

A version of this page is also available for

Windows Embedded CE 6.0 R3

4/8/2010

The following table shows the Windows-specific extension functions with a description of the purpose of each.

Programming element Description

WSAAccept

This function conditionally accepts a connection based on the return value of a condition function and allows the transfer of connection data.

WSAAddressToString

This function converts all parts of a sockaddr structure into a human-readable string representation of the address.

WSACleanup

This function terminates use of the ws2.dll.

WSACloseEvent

This function closes an open event object handle.

WSAConnect

This function establishes a connection to another socket application and exchanges connect (Windows Sockets) data.

WSACreateEvent

This function creates a new event object.

WSAEnumNameSpaceProviders

This function retrieves information about available name spaces.

WSAEnumNetworkEvents

This function discovers occurrences of network events for the indicated socket, clear internal network event records, and reset event objects (optional).

WSAEnumProtocols

This function retrieves information about available transport protocols.

WSAEventSelect

This function specifies an event object to be associated with the supplied set of FD_XXX network events.

WSAGetLastError

This function gets the error status for the last operation that failed.

WSAGetOverlappedResult

This function returns the results of an overlapped operation on the specified socket.

WSAHtonl

This function converts a u_long from host byte order to network byte order.

WSAHtons

This function converts a u_short from host byte order to network byte order.

WSAIoctl

This function allows for miscellaneous control of a socket.

WSAJoinLeaf

This function joins a leaf node into a multipoint session, and exchanges connect data.

WSALookupServiceBegin (Windows Sockets)

This function initiates a client query that is constrained by the information contained within a WSAQUERYSET (Windows Sockets) structure. This function only returns a handle, which should be used by subsequent calls to the WSALookupServiceNext (Windows Sockets) function to get the actual results.

WSALookupServiceEnd (Windows Sockets)

This function is called to free the handle after previous calls to WSALookupServiceBegin (Windows Sockets) and WSALookupServiceNext (Windows Sockets).

WSALookupServiceNext (Windows Sockets)

This function is called after obtaining a handle from a previous call to the WSALookupServiceBegin (Windows Sockets) function to retrieve the requested service information.

WSANSPIoctl

This function enables developers to make I/O control calls to a registered namespace.

WSANtohl

This function converts a u_long from network byte order to host byte order.

WSANtohs

This function converts a u_short from network byte order to host byte order.

WSARecv

This function receives data from a connected socket.

WSARecvFrom

This function receives data on a socket and stores the source address.

WSAResetEvent

This function resets the state of the specified event object to nonsignaled.

WSASend

This function sends data on a connected socket.

WSASendTo

This function sends data to a specific destination, using overlapped I/O where applicable.

WSASetEvent

This function sets the state of the specified event object to signaled.

WSASetLastError

This function sets the error code that can be retrieved through the WSAGetLastError function.

WSASetService (Windows Sockets)

This function registers or removes from the registry a service instance within one or more name spaces.

> [!NOTE] > This function is not supported for the default TCP/UDP provider. However, third parties can implement their own provider and have support for this function if they choose.

WSASocket

This function creates a socket that is bound to a specific transport service provider.

WSAStartup

This function initiates use of ws2.dll by a process.

WSAStringToAddress

This function converts a numeric string to a sockaddr structure suitable for passing to Windows Sockets routines that take such a structure.

WSAWaitForMultipleEvents

This function waits for multiple events and returns either when one or all of the specified event objects are in the signaled state, or when the timeout interval expires.