java.lang.Object
java.lang.Throwable
java.lang.Exception
java.lang.RuntimeException
ai.docling.serve.client.DoclingServeClientException
- All Implemented Interfaces:
Serializable
Exception thrown when an error occurs during a client request to the Docling Serve API.
This exception encapsulates additional details about the HTTP status code and the response
body returned by the server, providing more context for the error.
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionDoclingServeClientException(String message, int statusCode, String responseBody) -
Method Summary
Modifier and TypeMethodDescriptionRetrieves the response body associated with this exception.intRetrieves the HTTP status code associated with this exception.Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
Constructor Details
-
DoclingServeClientException
-
-
Method Details
-
getStatusCode
public int getStatusCode()Retrieves the HTTP status code associated with this exception.- Returns:
- the HTTP status code that was returned by the server.
-
getResponseBody
Retrieves the response body associated with this exception.- Returns:
- the response body returned by the server as a string.
-