public final class ResponseCodeHandler extends Object implements HttpHandler
| Modifier and Type | Field and Description |
|---|---|
static ResponseCodeHandler | HANDLE_200 A handler which sets a 200 code. |
static ResponseCodeHandler | HANDLE_403 A handler which sets a 403 code. |
static ResponseCodeHandler | HANDLE_404 A handler which sets a 404 code. |
static ResponseCodeHandler | HANDLE_405 A handler which sets a 405 code. |
static ResponseCodeHandler | HANDLE_406 A handler which sets a 406 code. |
static ResponseCodeHandler | HANDLE_500 A handler which sets a 500 code. |
| Constructor and Description |
|---|
ResponseCodeHandler(int responseCode) Construct a new instance. |
| Modifier and Type | Method and Description |
|---|---|
void | handleRequest(HttpServerExchange exchange) Handle the request. |
public static final ResponseCodeHandler HANDLE_200
public static final ResponseCodeHandler HANDLE_403
public static final ResponseCodeHandler HANDLE_404
public static final ResponseCodeHandler HANDLE_405
public static final ResponseCodeHandler HANDLE_406
public static final ResponseCodeHandler HANDLE_500
public ResponseCodeHandler(int responseCode)
responseCode - the response code to setpublic void handleRequest(HttpServerExchange exchange) throws Exception
HttpHandlerhandleRequest in interface HttpHandlerexchange - the HTTP request/response exchangeExceptionCopyright © 2020 JBoss by Red Hat. All rights reserved.