Class HandlerLogin
java.lang.Object
br.net.dd.netherwingcore.bnetserver.rest.handlers.HandlerLogin
- All Implemented Interfaces:
HttpHandler
HandlerLogin is responsible for handling requests to the /bnetserver/login/ endpoint.
This endpoint is likely used for processing login requests, which may involve validating user credentials,
initiating authentication processes, or providing responses related to login attempts.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidhandle(HttpExchange exchange) Handles incoming HTTP requests to the /bnetserver/login/ endpoint.
-
Constructor Details
-
HandlerLogin
public HandlerLogin()
-
-
Method Details
-
handle
Handles incoming HTTP requests to the /bnetserver/login/ endpoint. Depending on the HTTP method (GET or POST), it processes the request accordingly. For GET requests, it initializes form inputs and sends a JSON response with the form details. For POST requests, it logs the received request and sends a simple JSON response acknowledging the POST request.- Specified by:
handlein interfaceHttpHandler- Parameters:
exchange- The HttpExchange object representing the incoming HTTP request and response.- Throws:
IOException- If an I/O error occurs while handling the request.
-