Class HttpProblem
- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- java.lang.RuntimeException
-
- com.tietoevry.quarkus.resteasy.problem.HttpProblem
-
- All Implemented Interfaces:
Serializable
@Immutable public class HttpProblem extends RuntimeException
Representation of RFC7807 Problem schema.- See Also:
- Serialized Form
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classHttpProblem.Builder
-
Field Summary
Fields Modifier and Type Field Description static jakarta.ws.rs.core.MediaTypeMEDIA_TYPE
-
Constructor Summary
Constructors Modifier Constructor Description protectedHttpProblem(HttpProblem.Builder builder)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description static HttpProblem.Builderbuilder()static HttpProblem.Builderbuilder(HttpProblem original)Creates Builder instance and initializes it with fields from given HttpProblemStringgetDetail()Map<String,Object>getHeaders()URIgetInstance()Map<String,Object>getParameters()jakarta.ws.rs.core.Response.StatusTypegetStatus()Deprecated, for removal: This API element is subject to removal in a future version.Replaced bygetStatusCode(), will be removed in 4.0.0 release as part of minimizing dependencies to JaxRS/JakartaRS classes.intgetStatusCode()StringgetTitle()URIgetType()jakarta.ws.rs.core.ResponsetoResponse()static HttpProblemvalueOf(jakarta.ws.rs.core.Response.Status status)static HttpProblemvalueOf(jakarta.ws.rs.core.Response.Status status, String detail)-
Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
-
-
-
Constructor Detail
-
HttpProblem
protected HttpProblem(HttpProblem.Builder builder)
-
-
Method Detail
-
valueOf
public static HttpProblem valueOf(jakarta.ws.rs.core.Response.Status status)
-
valueOf
public static HttpProblem valueOf(jakarta.ws.rs.core.Response.Status status, String detail)
-
builder
public static HttpProblem.Builder builder()
-
builder
public static HttpProblem.Builder builder(HttpProblem original)
Creates Builder instance and initializes it with fields from given HttpProblem- Parameters:
original- Problem 'prototype'- Returns:
- Builder object with values taken from origin HttpProblem
-
getType
public URI getType()
-
getTitle
public String getTitle()
-
getStatusCode
public int getStatusCode()
-
getStatus
@Deprecated(since="3.1.0", forRemoval=true) public jakarta.ws.rs.core.Response.StatusType getStatus()
Deprecated, for removal: This API element is subject to removal in a future version.Replaced bygetStatusCode(), will be removed in 4.0.0 release as part of minimizing dependencies to JaxRS/JakartaRS classes.Returns null if status code has no representation in Response.Status enum.
-
getDetail
public String getDetail()
-
getInstance
public URI getInstance()
-
toResponse
public jakarta.ws.rs.core.Response toResponse()
-
-