RecordType Property

This property contains the record type.

Syntax

 dns.getRecordType(index, [callback])

Possible Values

  1 (rtAddress), 
  2 (rtNS), 
  3 (rtMD), 
  4 (rtMF), 
  5 (rtCName), 
  6 (rtSOA), 
  7 (rtMailBox), 
  8 (rtMailGroup), 
  9 (rtMR), 
  10 (rtNULL), 
  11 (rtWKS), 
  12 (rtPointer), 
  13 (rtHostInfo), 
  14 (rtMailInfo), 
  15 (rtMX), 
  16 (rtText), 
  17 (rtRP), 
  18 (rtAFSDB), 
  19 (rtX25), 
  20 (rtISDN), 
  21 (rtRT), 
  28 (rtAAAA), 
  33 (rtSRV), 
  35 (rtNAPTR)

Default Value

1

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 the getRecordType([callback]) method is defined as:

function(err, data){ }

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

'data' is the value returned by the method.

The callback for the setRecordType([callback]) 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 property contains the record type.

Record types correspond to QueryType and are defined as follows:

rtAddress (1)Address Record
rtNS (2)Name Server Record
rtMD (3)Mail Destination Record
rtMF (4)Mail Forwarder Record
rtCName (5)Canonical Name Record
rtSOA (6)Start Of Authority Record
rtMailBox (7)MailBox Record
rtMailGroup (8)Mail Group Record
rtMR (9)MailBox Rename Record
rtNULL (10)NULL Record
rtWKS (11)Well Known Services Record
rtPointer (12)Pointer Record
rtHostInfo (13)Host Information Record
rtMailInfo (14)Mail Information Record
rtMX (15)Mail Exchange Record
rtText (16)Text Record
rtRP (17)Responsible Person Record
rtAFSDB (18)Service Record
rtX25 (19)X25 Record
rtISDN (20)ISDN Record
rtRT (21)Route Through Record
rtAAAA (28)AAAA Record
rtSRV (33)SRV Record (location of services)
rtNAPTR (35)NAPTR Record (Naming Authority Pointer)

The index parameter specifies the index of the item in the array. The size of the array is controlled by the RecordCount property.

This property is read-only and not available at design time.

Data Type

Integer

Copyright (c) 2022 /n software inc. - All rights reserved.
IPWorks 2020 Node.js Edition - Version 20.0 [Build 8307]