Class HttpStatusHandler
- java.lang.Object
- org.springframework.boot.devtools.remote.server.HttpStatusHandler
- All Implemented Interfaces:
Handler
public class HttpStatusHandler extends Object implements Handler
Handlerthat responds with a specificHttpStatus.
Constructor Summary
Constructors Constructor Description HttpStatusHandler()Create a newHttpStatusHandlerinstance that will respond with a HTTP OK 200 status.HttpStatusHandler(org.springframework.http.HttpStatus status)Create a newHttpStatusHandlerinstance that will respond with the specified status.
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidhandle(org.springframework.http.server.ServerHttpRequest request, org.springframework.http.server.ServerHttpResponse response)Handle the request.
Constructor Detail
HttpStatusHandler
public HttpStatusHandler()
Create a newHttpStatusHandlerinstance that will respond with a HTTP OK 200 status.
HttpStatusHandler
public HttpStatusHandler(org.springframework.http.HttpStatus status)
Create a newHttpStatusHandlerinstance that will respond with the specified status.- Parameters:
status- the status
Method Detail
handle
public void handle(org.springframework.http.server.ServerHttpRequest request, org.springframework.http.server.ServerHttpResponse response) throws IOException
Description copied from interface:HandlerHandle the request.- Specified by:
handlein interfaceHandler- Parameters:
request- the requestresponse- the response- Throws:
IOException- in case of I/O errors