Package | Description |
---|---|
org.springframework.http |
Contains a basic abstraction over client/server-side HTTP.
|
Modifier and Type | Method and Description |
---|---|
static ResponseEntity.BodyBuilder |
ResponseEntity.accepted()
Create a builder with an ACCEPTED status.
|
static ResponseEntity.BodyBuilder |
ResponseEntity.badRequest()
Create a builder with a BAD_REQUEST status.
|
ResponseEntity.BodyBuilder |
ResponseEntity.BodyBuilder.contentLength(long contentLength)
Set the length of the body in bytes, as specified by the
Content-Length header. |
ResponseEntity.BodyBuilder |
ResponseEntity.BodyBuilder.contentType(MediaType contentType)
Set the media type of the body, as specified by the
Content-Type header. |
static ResponseEntity.BodyBuilder |
ResponseEntity.created(URI location)
Create a new builder with a CREATED status
and a location header set to the given URI.
|
static ResponseEntity.BodyBuilder |
ResponseEntity.internalServerError()
Create a builder with an
INTERNAL_SERVER_ERROR status.
|
static ResponseEntity.BodyBuilder |
ResponseEntity.ok()
Create a builder with the status set to OK.
|
static ResponseEntity.BodyBuilder |
ResponseEntity.status(HttpStatus status)
Create a builder with the given status.
|
static ResponseEntity.BodyBuilder |
ResponseEntity.status(int status)
Create a builder with the given status.
|
static ResponseEntity.BodyBuilder |
ResponseEntity.unprocessableEntity()
Create a builder with an
UNPROCESSABLE_ENTITY status.
|