Development · Native API migration preview · Coverage validation in progress Published release →

API Browser

Method

GetHostAddresses

static func GetHostAddresses(hostName: string, cancellationToken: CancellationToken = default) -> Task<Result<Sequence<IPAddress>, DnsError>>

Declaring type: Dns
Module: System.Networking
Assembly: System.Networking.dll
Source file: Dns.rvn

Requests cancellation cooperatively; the task is cancelled after provider acknowledgement.

Parameters

Name Type Description
hostName String
cancellationToken CancellationToken

Return value

Task<Result<Sequence<IPAddress>, DnsError>>