Skip to content

Latest commit

 

History

History
39 lines (27 loc) · 2.04 KB

datagramsocket_getendpointpairsasync_903639760.md

File metadata and controls

39 lines (27 loc) · 2.04 KB
-api-id -api-type
M:Windows.Networking.Sockets.DatagramSocket.GetEndpointPairsAsync(Windows.Networking.HostName,System.String,Windows.Networking.HostNameSortOptions)
winrt method

Windows.Networking.Sockets.DatagramSocket.GetEndpointPairsAsync

-description

Gets a list of EndpointPair objects based on a remote hostname and remote service name and the sort order to be used.

-parameters

-param remoteHostName

The remote hostname or IP address.

-param remoteServiceName

The remote service name or UDP port.

-param sortOptions

The sort order to use when returning the list.

-returns

A list of EndpointPair objects.

-remarks

The GetEndpointPairsAsync method gets a list of possible EndpointPair objects that can be used by a DatagramSocket to connect to a remote network destination. The returned list is sorted based on the sortOptions parameter.

A DatagramSocket can use the list returned by the GetEndpointPairsAsync method to try and bind or connect to each EndpointPair object until a remote destination can be reached. An EndpointPair object from the list would be used with the ConnectAsync(EndpointPair) method.

-examples

-see-also

ConnectAsync(EndpointPair), EndpointPair, GetEndpointPairsAsync(HostName, String), HostName

-capabilities

ID_CAP_NETWORKING [Windows Phone]