Package com.influxdb.exceptions
Class InfluxException
java.lang.Object
java.lang.Throwable
java.lang.Exception
java.lang.RuntimeException
com.influxdb.exceptions.InfluxException
- All Implemented Interfaces:
Serializable
- Direct Known Subclasses:
BadGatewayException,BadRequestException,FluxCsvParserException,FluxQueryException,ForbiddenException,GatewayTimeoutException,InternalServerErrorException,MethodNotAllowedException,NotAcceptableException,NotFoundException,NotImplementedException,PaymentRequiredException,ProxyAuthenticationRequiredException,RequestEntityTooLargeException,RequestTimeoutException,ServiceUnavailableException,UnauthorizedException,UnprocessableEntityException
The base type for Influx errors.
- Author:
- Jakub Bednar (bednar@github) (31/07/2018 11:53)
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionInfluxException(String message) InfluxException(Throwable cause) InfluxException(retrofit2.Response<?> cause) -
Method Summary
Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
Constructor Details
-
InfluxException
-
InfluxException
-
InfluxException
public InfluxException(@Nullable retrofit2.Response<?> cause)
-
-
Method Details
-
getMessage
- Overrides:
getMessagein classThrowable
-
reference
public int reference()Gets the reference code unique to the error type. If the reference code is not present then return "0".- Returns:
- reference code unique to the error type
-
status
public int status()Gets the HTTP status code of the unsuccessful response. If the response is not present then return "0".- Returns:
- HTTP status code
-
headers
Gets the HTTP headers from the unsuccessful response. If the response is not present then return emptyMap.- Returns:
- HTTP headers
-
errorBody
The JSON unsuccessful response body.- Returns:
- a response body
-