function promises.resolve
Overload 1
#resolve(hostname: string): Promise<string[]>Uses the DNS protocol to resolve a host name (e.g. 'nodejs.org') into an array
of the resource records. When successful, the Promise is resolved with an
array of resource records. The type and structure of individual results vary
based on rrtype:
On error, the Promise is rejected with an Error object, where err.code
is one of the DNS error codes.
Parameters #
#hostname: string Host name to resolve.
Return Type #
Promise<string[]> Overload 2
#resolve(hostname: string,rrtype: "A",): Promise<string[]>Overload 3
#resolve(hostname: string,rrtype: "AAAA",): Promise<string[]>Overload 4
Overload 5
Overload 6
#resolve(hostname: string,rrtype: "CNAME",): Promise<string[]>Overload 7
Overload 8
#resolve(hostname: string,rrtype: "NAPTR",): Promise<NaptrRecord[]>Parameters #
Return Type #
Promise<NaptrRecord[]> Overload 9
#resolve(hostname: string,rrtype: "NS",): Promise<string[]>Overload 10
#resolve(hostname: string,rrtype: "PTR",): Promise<string[]>Overload 11
Overload 12
Overload 13
#resolve(hostname: string,rrtype: "TXT",): Promise<string[][]>Overload 14
#resolve(hostname: string,rrtype: string,): Promise<>