Interface HttpError


public interface HttpError
The object describing an HTTP error.
See Also:
  • Method Summary

    Modifier and Type
    Method
    Description
    Returns the body of the HTTP response, if any.
    Returns the headers of the HTTP response.
    Returns the HTTP method of the request that failed.
    Returns the exact URL of the request that failed.
    int
    Returns the HTTP status code returned by the server.
  • Method Details

    • statusCode

      int statusCode()
      Returns the HTTP status code returned by the server.
      Returns:
      the HTTP status code
    • requestUrl

      @NonNull URI requestUrl()
      Returns the exact URL of the request that failed.
      Returns:
      the URL of the failed request
    • body

      @NonNull Optional<String> body()
      Returns the body of the HTTP response, if any.
      Returns:
      the body of the HTTP response
    • headers

      @NonNull ResponseHeaders headers()
      Returns the headers of the HTTP response.
      Returns:
      the headers of the HTTP response
    • method

      @NonNull String method()
      Returns the HTTP method of the request that failed.
      Returns:
      the HTTP method of the request.