Class HttpErrorException

java.lang.Object
java.lang.Throwable
java.lang.Exception
io.metaloom.qdrant.client.http.impl.HttpErrorException
All Implemented Interfaces:
Serializable

public class HttpErrorException extends Exception
Exception which is also used to return non-200 error responses.
See Also:
  • Constructor Details

    • HttpErrorException

      public HttpErrorException(String message, int statusCode, String body)
    • HttpErrorException

      public HttpErrorException(String message, Exception e)
  • Method Details

    • getBody

      public String getBody()
      Returns the error response body.
      Returns:
    • getStatusCode

      public int getStatusCode()
      Returns the error HTTTP status code.
      Returns:
    • getError

      public ErrorResponse getError()
      Return the server error response.
      Returns:
    • getBodyObject

      public <T> T getBodyObject(Function<String,T> parser)
      Transform the body string into the object of choice.
      Parameters:
      parser - Function used to transform the string.
      Returns:
    • toString

      public String toString()
      Overrides:
      toString in class Throwable