Package de.dytanic.cloudnet.http
Class V1HttpHandler
- java.lang.Object
-
- de.dytanic.cloudnet.driver.network.http.MethodHttpHandlerAdapter
-
- de.dytanic.cloudnet.http.V1HttpHandler
-
- All Implemented Interfaces:
de.dytanic.cloudnet.driver.network.http.IHttpHandler,de.dytanic.cloudnet.driver.network.http.IMethodHttpHandler
public abstract class V1HttpHandler extends de.dytanic.cloudnet.driver.network.http.MethodHttpHandlerAdapter
-
-
Field Summary
Fields Modifier and Type Field Description protected static com.google.gson.GsonGSONprotected static V1HttpSessionHTTP_SESSION
-
Constructor Summary
Constructors Constructor Description V1HttpHandler(java.lang.String permission)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected booleancheckPermission(de.dytanic.cloudnet.driver.network.http.IHttpContext context, java.lang.String permission)protected booleancontainsStringElementInCollection(java.util.Collection<java.lang.String> collection, java.lang.String name)protected CloudNetgetCloudNet()java.lang.StringgetPermission()voidhandle(java.lang.String path, de.dytanic.cloudnet.driver.network.http.IHttpContext context)protected de.dytanic.cloudnet.driver.network.http.IHttpContextsend400Response(de.dytanic.cloudnet.driver.network.http.IHttpContext context, java.lang.String reason)protected de.dytanic.cloudnet.driver.network.http.IHttpContextsend403Response(de.dytanic.cloudnet.driver.network.http.IHttpContext context, java.lang.String reason)protected de.dytanic.cloudnet.driver.network.http.IHttpContextsendOptions(de.dytanic.cloudnet.driver.network.http.IHttpContext context, java.lang.String allowedMethods)
-
-
-
Field Detail
-
GSON
protected static final com.google.gson.Gson GSON
-
HTTP_SESSION
protected static final V1HttpSession HTTP_SESSION
-
-
Method Detail
-
handle
public void handle(java.lang.String path, de.dytanic.cloudnet.driver.network.http.IHttpContext context) throws java.lang.Exception- Throws:
java.lang.Exception
-
send400Response
protected de.dytanic.cloudnet.driver.network.http.IHttpContext send400Response(de.dytanic.cloudnet.driver.network.http.IHttpContext context, java.lang.String reason)
-
send403Response
protected de.dytanic.cloudnet.driver.network.http.IHttpContext send403Response(de.dytanic.cloudnet.driver.network.http.IHttpContext context, java.lang.String reason)
-
sendOptions
protected de.dytanic.cloudnet.driver.network.http.IHttpContext sendOptions(de.dytanic.cloudnet.driver.network.http.IHttpContext context, java.lang.String allowedMethods)
-
checkPermission
protected boolean checkPermission(de.dytanic.cloudnet.driver.network.http.IHttpContext context, java.lang.String permission)
-
containsStringElementInCollection
protected boolean containsStringElementInCollection(java.util.Collection<java.lang.String> collection, java.lang.String name)
-
getCloudNet
protected final CloudNet getCloudNet()
-
getPermission
public java.lang.String getPermission()
-
-