Package com.microsoft.kiota
Class ApiException
java.lang.Object
java.lang.Throwable
java.lang.Exception
java.lang.RuntimeException
com.microsoft.kiota.ApiException
- All Implemented Interfaces:
Serializable
Parent type for exceptions thrown by the client when receiving failed responses to its requests.
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionApiException(String message) ApiException(String message, Throwable cause) ApiException(Throwable cause) -
Method Summary
Modifier and TypeMethodDescriptionGets the HTTP response headers for the error responseintGets the HTTP response status codeprotected voidsetResponseHeaders(ResponseHeaders responseHeaders) Sets the HTTP response headers for the error responseprotected voidsetResponseStatusCode(int responseStatusCode) Sets the HTTP response status codeMethods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
Constructor Details
-
ApiException
public ApiException() -
ApiException
-
ApiException
-
ApiException
-
-
Method Details
-
getResponseStatusCode
public int getResponseStatusCode()Gets the HTTP response status code- Returns:
- The response status code from the failed response.
-
setResponseStatusCode
protected void setResponseStatusCode(int responseStatusCode) Sets the HTTP response status code- Parameters:
responseStatusCode- The response status code to set.
-
getResponseHeaders
Gets the HTTP response headers for the error response- Returns:
- The response headers collections from the failed response.
-
setResponseHeaders
Sets the HTTP response headers for the error response- Parameters:
responseHeaders- The response headers collections to set.
-