Package com.mongodb.spi.dns
Class DnsWithResponseCodeException
java.lang.Object
java.lang.Throwable
java.lang.Exception
java.lang.RuntimeException
com.mongodb.spi.dns.DnsException
com.mongodb.spi.dns.DnsWithResponseCodeException
- All Implemented Interfaces:
 Serializable
An exception indicating a DNS error that includes a response code.
- Since:
 - 4.6
 
- 
Constructor Summary
ConstructorsConstructorDescriptionDnsWithResponseCodeException(String message, int responseCode, Throwable cause) Construct an instance - 
Method Summary
Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString 
- 
Constructor Details
- 
DnsWithResponseCodeException
Construct an instance- Parameters:
 message- the messageresponseCode- the DNS response codecause- the cause
 
 - 
 - 
Method Details
- 
getResponseCode
public int getResponseCode()Gets the response code- Returns:
 - the response code
 
 
 -