Interface ErrorResponseBodyProvider<T>

Type Parameters:
T - The body type
All Known Subinterfaces:
HtmlErrorResponseBodyProvider, JsonErrorResponseBodyProvider<T>

public interface ErrorResponseBodyProvider<T>
Provides an HTTP Response body of an error response.
Since:
4.7.0
Author:
Sergio del Amo
  • Method Details

    • body

      @NonNull T body(@NonNull ErrorContext errorContext, @NonNull HttpResponse<?> response)
      Parameters:
      errorContext - Error Context
      response - Base HTTP Response
      Returns:
      The HTTP Response Body
    • contentType

      @NonNull String contentType()
      Returns:
      The content type of the HTTP response