An NDoc Documented Class Library |
|
DNSLookup Constructor
DNSLookup Constructor looks up a requested record on a given server. The lookup is done in the constructor itself. If there is any error, an exception is throw.
Parameters
-
query
- The string indicating the hostname/domainname/ipaddress for which the record lookup will be done.
-
qtype
- The Record type that needs to be looked up. QTYPE_A is for address, QTYPE_NS if for Name server, QTYPE_MX for Mail Exchange....
-
qclass
- The Record scheme on which the lookup should be performed. The most widely used scheme is Internet ( QCLASS_IN ).
-
timeout
- The Timeout in milliseconds to wait for the response from the server. If reponse is not recived with the timeout period, a SocketTimeoutException is thrown.
-
server
- The Domain Name Server on which the lookup has to be performed. This could be a hostname or a IP address. If null can be passed, the DNS setting from the system would be used.
Exceptions
Exception Type |
Condition |
SocketException
|
If a reponse is not received within the timeout period. |
Exception
|
If the Name Server can't be determined or any other internal problem occurs. |
See Also
DNSLookup Class | Lavantech.Dns Namespace