java.lang.Object
org.apache.jena.fuseki.servlets.ServletOps
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic void
error
(int statusCode) static void
static void
errorBadRequest
(String string) static void
static void
errorForbidden
(String msg) static void
errorMethodNotAllowed
(String method) static void
errorMethodNotAllowed
(String method, String msg) static void
static void
errorNotFound
(String string) static void
static void
errorOccurred
(String message) static void
errorOccurred
(String message, Throwable ex) static void
static void
errorParseError
(org.apache.jena.riot.RiotParseException ex) static String
formatForLog
(String string) static void
responseSendError
(jakarta.servlet.http.HttpServletResponse response, int statusCode) Send an HTTP response with no bodystatic void
responseSendError
(jakarta.servlet.http.HttpServletResponse response, int statusCode, String message) Send an HTTP error response.static void
sendJson
(HttpAction action, org.apache.jena.atlas.json.JsonValue jValue) Send a JSON value as a 200 response.static void
sendJsonReponse
(HttpAction action, org.apache.jena.atlas.json.JsonValue v) Send a JSON value as a 200 response.static void
setNoCache
(jakarta.servlet.http.HttpServletResponse response) static void
setNoCache
(HttpAction action) static void
success
(HttpAction action) static void
success
(HttpAction action, int httpStatusCode) static void
successCreated
(HttpAction action) static void
successNoContent
(HttpAction action) static void
successNotFound
(HttpAction action) static void
successPage
(HttpAction action, String message) static void
uploadResponse
(HttpAction action, UploadDetails details) response to a upload operation of some kind.static void
warning
(HttpAction action, String string) static void
warning
(HttpAction action, String string, Throwable thorwable) static void
writeMessagePlainTextError
(jakarta.servlet.http.HttpServletResponse response, String message)
-
Constructor Details
-
ServletOps
public ServletOps()
-
-
Method Details
-
responseSendError
public static void responseSendError(jakarta.servlet.http.HttpServletResponse response, int statusCode, String message) Send an HTTP error response. Include an optional message in the body (as text/plain), if provided. Note that we do not set a custom Reason Phrase.
HTTPS/2 does not have a "Reason Phrase".- Parameters:
response
-statusCode
-message
-
-
responseSendError
public static void responseSendError(jakarta.servlet.http.HttpServletResponse response, int statusCode) Send an HTTP response with no body -
writeMessagePlainTextError
public static void writeMessagePlainTextError(jakarta.servlet.http.HttpServletResponse response, String message) -
successNoContent
-
success
-
successCreated
-
successNotFound
-
success
-
successPage
-
warning
-
warning
-
errorParseError
public static void errorParseError(org.apache.jena.riot.RiotParseException ex) -
errorBadRequest
-
errorNotFound
public static void errorNotFound() -
errorNotFound
-
errorNotImplemented
-
errorMethodNotAllowed
-
errorMethodNotAllowed
-
errorForbidden
public static void errorForbidden() -
errorForbidden
-
error
public static void error(int statusCode) -
error
-
errorOccurred
-
errorOccurred
-
errorOccurred
-
formatForLog
-
setNoCache
-
setNoCache
public static void setNoCache(jakarta.servlet.http.HttpServletResponse response) -
uploadResponse
response to a upload operation of some kind. -
sendJsonReponse
Send a JSON value as a 200 response. Null object means no response body and no content-type headers. -
sendJson
Send a JSON value as a 200 response. Null object means no response body and no content-type headers.
-