Example usage for Java org.springframework.http ResponseEntity fields, constructors, methods, implement or subclass
The text is from its open source code.
Object | status |
ResponseEntity(HttpStatus status) Create a new ResponseEntity with the given status code, and no body nor headers. | |
ResponseEntity(@Nullable T body, HttpStatus status) Create a new ResponseEntity with the given body and status code, and no headers. | |
ResponseEntity(MultiValueMap Create a new HttpEntity with the given headers and status code, and no body. | |
ResponseEntity(@Nullable T body, @Nullable MultiValueMap Create a new HttpEntity with the given body, headers, and status code. | |
ResponseEntity(@Nullable T body, @Nullable MultiValueMap Create a new HttpEntity with the given body, headers, and status code. |
BodyBuilder | accepted() Create a builder with an HttpStatus#ACCEPTED ACCEPTED status. |
BodyBuilder | badRequest() Create a builder with a HttpStatus#BAD_REQUEST BAD_REQUEST status. |
BodyBuilder | created(URI location) Create a new builder with a HttpStatus#CREATED CREATED status and a location header set to the given URI. |
HttpStatus | getStatusCode() Return the HTTP status code of the response. |
int | getStatusCodeValue() Return the HTTP status code of the response. |
HeadersBuilder> | noContent() Create a builder with a HttpStatus#NO_CONTENT NO_CONTENT status. |
HeadersBuilder> | notFound() Create a builder with a HttpStatus#NOT_FOUND NOT_FOUND status. |
ResponseEntity | ok(T body) A shortcut for creating a ResponseEntity with the given body and the status set to HttpStatus#OK OK . |
BodyBuilder | ok() Create a builder with the status set to HttpStatus#OK OK . |
String | toString() |
BodyBuilder | unprocessableEntity() Create a builder with an HttpStatus#UNPROCESSABLE_ENTITY UNPROCESSABLE_ENTITY status. |