Package emu.grasscutter.server.http
Class HttpServer
java.lang.Object
emu.grasscutter.server.http.HttpServer
Manages all HTTP-related classes.
(including dispatch, announcements, gacha, etc.)
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classHandles the '/' (index) endpoint on the Express application.static classHandles unhandled endpoints on the Express application. -
Constructor Summary
Constructors -
Method Summary
-
Constructor Details
-
HttpServer
public HttpServer()Configures the Express application.
-
-
Method Details
-
getHandle
public io.javalin.Javalin getHandle()Returns the handle for the Express application.- Returns:
- A Javalin instance.
-
addRouter
Initializes the provided class.- Parameters:
router- The router class.- Returns:
- Method chaining.
-
start
public void start()Starts listening on the HTTP server.
-