IP*Works! 2016 Node.js Edition
IP*Works! 2016 Node.js Edition
Questions / Feedback?

Query Method

Query a Domain.

Syntax

dns.query(domain, [callback])

Callback

The 'callback' parameter specifies a function which will be called when the operation completes (or an error is encountered). If the 'callback' parameter is not specified, then the method will block and will not return until the operation completes (or an error is encountered).

The callback for this method is defined as:

function(err){ }

'err' is the error that occurred. If there was no error, then 'err' is 'null'.

'err' has 2 properties which hold detailed information:

err.code
err.message

Remarks

This method will query the host Domain for any records of the type in QueryType. After the query, RequestId is the identifier corresponding to the request. Once the query is complete, a single Response event will fire, and the following properties will contain the results:

StatusCodeThe success or error code of the DNS query.
StatusA standard string interpretation of StatusCode.
RecordsThe Records in the last DNS response.
RecordSourceThe source (type) of records being listed.

 
 
Copyright (c) 2019 /n software inc. - All rights reserved.
IP*Works! 2016 Node.js Edition - Version 16.0 [Build 7239]