public class Results
extends java.lang.Object
Constructor and Description |
---|
Results() |
Modifier and Type | Method and Description |
---|---|
static StatusHeader |
badRequest()
Generates a 400 Bad Request result.
|
static Result |
badRequest(byte[] content)
Generates a 400 Bad Request result.
|
static Result |
badRequest(play.twirl.api.Content content)
Generates a 400 Bad Request result.
|
static Result |
badRequest(play.twirl.api.Content content,
java.lang.String charset)
Generates a 400 Bad Request result.
|
static Result |
badRequest(java.io.File content)
Generates a 400 Bad Request result.
|
static Result |
badRequest(java.io.File content,
boolean inline)
Generates a 400 Bad Request result.
|
static Result |
badRequest(java.io.File content,
java.lang.String filename)
Generates a 400 Bad Request result.
|
static Result |
badRequest(java.io.InputStream content)
Generates a 400 Bad Request result.
|
static Result |
badRequest(java.io.InputStream content,
long contentLength)
Generates a 400 Bad Request result.
|
static Result |
badRequest(com.fasterxml.jackson.databind.JsonNode content)
Generates a 400 Bad Request result.
|
static Result |
badRequest(com.fasterxml.jackson.databind.JsonNode content,
com.fasterxml.jackson.core.JsonEncoding encoding)
Generates a 400 Bad Request result.
|
static Result |
badRequest(java.lang.String content)
Generates a 400 Bad Request result.
|
static Result |
badRequest(java.lang.String content,
java.lang.String charset)
Generates a 400 Bad Request result.
|
static StatusHeader |
created()
Generates a 201 Created result.
|
static Result |
created(byte[] content)
Generates a 201 Created result.
|
static Result |
created(play.twirl.api.Content content)
Generates a 201 Created result.
|
static Result |
created(play.twirl.api.Content content,
java.lang.String charset)
Generates a 201 Created result.
|
static Result |
created(java.io.File content)
Generates a 201 Created result.
|
static Result |
created(java.io.File content,
boolean inline)
Generates a 201 Created result.
|
static Result |
created(java.io.File content,
java.lang.String filename)
Generates a 201 Created result.
|
static Result |
created(java.io.InputStream content)
Generates a 201 Created result.
|
static Result |
created(java.io.InputStream content,
long contentLength)
Generates a 201 Created result.
|
static Result |
created(com.fasterxml.jackson.databind.JsonNode content)
Generates a 201 Created result.
|
static Result |
created(com.fasterxml.jackson.databind.JsonNode content,
com.fasterxml.jackson.core.JsonEncoding encoding)
Generates a 201 Created result.
|
static Result |
created(java.lang.String content)
Generates a 201 Created result.
|
static Result |
created(java.lang.String content,
java.lang.String charset)
Generates a 201 Created result.
|
static StatusHeader |
forbidden()
Generates a 403 Forbidden result.
|
static Result |
forbidden(byte[] content)
Generates a 403 Forbidden result.
|
static Result |
forbidden(play.twirl.api.Content content)
Generates a 403 Forbidden result.
|
static Result |
forbidden(play.twirl.api.Content content,
java.lang.String charset)
Generates a 403 Forbidden result.
|
static Result |
forbidden(java.io.File content)
Generates a 403 Forbidden result.
|
static Result |
forbidden(java.io.File content,
boolean inline)
Generates a 403 Forbidden result.
|
static Result |
forbidden(java.io.File content,
java.lang.String filename)
Generates a 403 Forbidden result.
|
static Result |
forbidden(java.io.InputStream content)
Generates a 403 Forbidden result.
|
static Result |
forbidden(java.io.InputStream content,
long contentLength)
Generates a 403 Forbidden result.
|
static Result |
forbidden(com.fasterxml.jackson.databind.JsonNode content)
Generates a 403 Forbidden result.
|
static Result |
forbidden(com.fasterxml.jackson.databind.JsonNode content,
com.fasterxml.jackson.core.JsonEncoding encoding)
Generates a 403 Forbidden result.
|
static Result |
forbidden(java.lang.String content)
Generates a 403 Forbidden result.
|
static Result |
forbidden(java.lang.String content,
java.lang.String charset)
Generates a 403 Forbidden result.
|
static Result |
found(Call call)
Generates a 302 Found result.
|
static Result |
found(java.lang.String url)
Generates a 302 Found result.
|
static StatusHeader |
internalServerError()
Generates a 500 Internal Server Error result.
|
static Result |
internalServerError(byte[] content)
Generates a 500 Internal Server Error result.
|
static Result |
internalServerError(play.twirl.api.Content content)
Generates a 500 Internal Server Error result.
|
static Result |
internalServerError(play.twirl.api.Content content,
java.lang.String charset)
Generates a 500 Internal Server Error result.
|
static Result |
internalServerError(java.io.File content)
Generates a 500 Internal Server Error result.
|
static Result |
internalServerError(java.io.File content,
boolean inline)
Generates a 500 Internal Server Error result.
|
static Result |
internalServerError(java.io.File content,
java.lang.String filename)
Generates a 500 Internal Server Error result.
|
static Result |
internalServerError(java.io.InputStream content)
Generates a 500 Internal Server Error result.
|
static Result |
internalServerError(java.io.InputStream content,
long contentLength)
Generates a 500 Internal Server Error result.
|
static Result |
internalServerError(com.fasterxml.jackson.databind.JsonNode content)
Generates a 500 Internal Server Error result.
|
static Result |
internalServerError(com.fasterxml.jackson.databind.JsonNode content,
com.fasterxml.jackson.core.JsonEncoding encoding)
Generates a 500 Internal Server Error result.
|
static Result |
internalServerError(java.lang.String content)
Generates a 500 Internal Server Error result.
|
static Result |
internalServerError(java.lang.String content,
java.lang.String charset)
Generates a 500 Internal Server Error result.
|
static Result |
movedPermanently(Call call)
Generates a 301 Moved Permanently result.
|
static Result |
movedPermanently(java.lang.String url)
Generates a 301 Moved Permanently result.
|
static StatusHeader |
noContent()
Generates a 204 No Content result.
|
static StatusHeader |
notAcceptable()
Generates a 406 Not Acceptable result.
|
static Result |
notAcceptable(byte[] content)
Generates a 406 Not Acceptable result.
|
static Result |
notAcceptable(play.twirl.api.Content content)
Generates a 406 Not Acceptable result.
|
static Result |
notAcceptable(play.twirl.api.Content content,
java.lang.String charset)
Generates a 406 Not Acceptable result.
|
static Result |
notAcceptable(java.io.File content)
Generates a 406 Not Acceptable result.
|
static Result |
notAcceptable(java.io.File content,
boolean inline)
Generates a 406 Not Acceptable result.
|
static Result |
notAcceptable(java.io.File content,
java.lang.String filename)
Generates a 406 Not Acceptable result.
|
static Result |
notAcceptable(java.io.InputStream content)
Generates a 406 Not Acceptable result.
|
static Result |
notAcceptable(java.io.InputStream content,
long contentLength)
Generates a 406 Not Acceptable result.
|
static Result |
notAcceptable(com.fasterxml.jackson.databind.JsonNode content)
Generates a 406 Not Acceptable result.
|
static Result |
notAcceptable(com.fasterxml.jackson.databind.JsonNode content,
com.fasterxml.jackson.core.JsonEncoding encoding)
Generates a 406 Not Acceptable result.
|
static Result |
notAcceptable(java.lang.String content)
Generates a 406 Not Acceptable result.
|
static Result |
notAcceptable(java.lang.String content,
java.lang.String charset)
Generates a 406 Not Acceptable result.
|
static StatusHeader |
notFound()
Generates a 404 Not Found result.
|
static Result |
notFound(byte[] content)
Generates a 404 Not Found result.
|
static Result |
notFound(play.twirl.api.Content content)
Generates a 404 Not Found result.
|
static Result |
notFound(play.twirl.api.Content content,
java.lang.String charset)
Generates a 404 Not Found result.
|
static Result |
notFound(java.io.File content)
Generates a 404 Not Found result.
|
static Result |
notFound(java.io.File content,
boolean inline)
Generates a 404 Not Found result.
|
static Result |
notFound(java.io.File content,
java.lang.String filename)
Generates a 404 Not Found result.
|
static Result |
notFound(java.io.InputStream content)
Generates a 404 Not Found result.
|
static Result |
notFound(java.io.InputStream content,
long contentLength)
Generates a 404 Not Found result.
|
static Result |
notFound(com.fasterxml.jackson.databind.JsonNode content)
Generates a 404 Not Found result.
|
static Result |
notFound(com.fasterxml.jackson.databind.JsonNode content,
com.fasterxml.jackson.core.JsonEncoding encoding)
Generates a 404 Not Found result.
|
static Result |
notFound(java.lang.String content)
Generates a 404 Not Found result.
|
static Result |
notFound(java.lang.String content,
java.lang.String charset)
Generates a 404 Not Found result.
|
static StatusHeader |
ok()
Generates a 200 OK result.
|
static Result |
ok(byte[] content)
Generates a 200 OK result.
|
static Result |
ok(play.twirl.api.Content content)
Generates a 200 OK result.
|
static Result |
ok(play.twirl.api.Content content,
java.lang.String charset)
Generates a 200 OK result.
|
static Result |
ok(java.io.File content)
Generates a 200 OK result.
|
static Result |
ok(java.io.File content,
boolean inline)
Generates a 200 OK result.
|
static Result |
ok(java.io.File content,
java.lang.String filename)
Generates a 200 OK result.
|
static Result |
ok(java.io.InputStream content)
Generates a 200 OK result.
|
static Result |
ok(java.io.InputStream content,
long contentLength)
Generates a 200 OK result.
|
static Result |
ok(com.fasterxml.jackson.databind.JsonNode content)
Generates a 200 OK result.
|
static Result |
ok(com.fasterxml.jackson.databind.JsonNode content,
com.fasterxml.jackson.core.JsonEncoding encoding)
Generates a 200 OK result.
|
static Result |
ok(java.lang.String content)
Generates a 200 OK result.
|
static Result |
ok(java.lang.String content,
java.lang.String charset)
Generates a 200 OK result.
|
static StatusHeader |
paymentRequired()
Generates a 402 Payment Required result.
|
static Result |
paymentRequired(byte[] content)
Generates a 402 Payment Required result.
|
static Result |
paymentRequired(play.twirl.api.Content content)
Generates a 402 Payment Required result.
|
static Result |
paymentRequired(play.twirl.api.Content content,
java.lang.String charset)
Generates a 402 Payment Required result.
|
static Result |
paymentRequired(java.io.File content)
Generates a 402 Payment Required result.
|
static Result |
paymentRequired(java.io.File content,
boolean inline)
Generates a 402 Payment Required result.
|
static Result |
paymentRequired(java.io.File content,
java.lang.String filename)
Generates a 402 Payment Required result.
|
static Result |
paymentRequired(java.io.InputStream content)
Generates a 402 Payment Required result.
|
static Result |
paymentRequired(java.io.InputStream content,
long contentLength)
Generates a 402 Payment Required result.
|
static Result |
paymentRequired(com.fasterxml.jackson.databind.JsonNode content)
Generates a 402 Payment Required result.
|
static Result |
paymentRequired(com.fasterxml.jackson.databind.JsonNode content,
com.fasterxml.jackson.core.JsonEncoding encoding)
Generates a 402 Payment Required result.
|
static Result |
paymentRequired(java.lang.String content)
Generates a 402 Payment Required result.
|
static Result |
paymentRequired(java.lang.String content,
java.lang.String charset)
Generates a 402 Payment Required result.
|
static Result |
permanentRedirect(Call call)
Generates a 308 Permanent Redirect result.
|
static Result |
permanentRedirect(java.lang.String url)
Generates a 308 Permanent Redirect result.
|
static Result |
redirect(Call call)
Generates a 303 See Other result.
|
static Result |
redirect(java.lang.String url)
Generates a 303 See Other result.
|
static Result |
seeOther(Call call)
Generates a 303 See Other result.
|
static Result |
seeOther(java.lang.String url)
Generates a 303 See Other result.
|
static StatusHeader |
status(int status)
Generates a simple result.
|
static Result |
status(int status,
byte[] content)
Generates a simple result with byte-array content.
|
static Result |
status(int status,
akka.util.ByteString content)
Generates a simple result.
|
static Result |
status(int status,
play.twirl.api.Content content)
Generates a simple result.
|
static Result |
status(int status,
play.twirl.api.Content content,
java.lang.String charset)
Generates a simple result.
|
static Result |
status(int status,
java.io.File content)
Generates a result with file contents.
|
static Result |
status(int status,
java.io.File content,
boolean inline)
Generates a result with file content.
|
static Result |
status(int status,
java.io.File content,
java.lang.String fileName)
Generates a result.
|
static Result |
status(int status,
java.io.InputStream content)
Generates a chunked result.
|
static Result |
status(int status,
java.io.InputStream content,
long contentLength)
Generates a chunked result.
|
static Result |
status(int status,
com.fasterxml.jackson.databind.JsonNode content)
Generates a simple result with json content and UTF8 encoding.
|
static Result |
status(int status,
com.fasterxml.jackson.databind.JsonNode content,
com.fasterxml.jackson.core.JsonEncoding encoding)
Generates a simple result with json content.
|
static Result |
status(int status,
java.lang.String content)
Generates a simple result.
|
static Result |
status(int status,
java.lang.String content,
java.lang.String charset)
Generates a simple result.
|
static Result |
temporaryRedirect(Call call)
Generates a 307 Temporary Redirect result.
|
static Result |
temporaryRedirect(java.lang.String url)
Generates a 307 Temporary Redirect result.
|
static StatusHeader |
unauthorized()
Generates a 401 Unauthorized result.
|
static Result |
unauthorized(byte[] content)
Generates a 401 Unauthorized result.
|
static Result |
unauthorized(play.twirl.api.Content content)
Generates a 401 Unauthorized result.
|
static Result |
unauthorized(play.twirl.api.Content content,
java.lang.String charset)
Generates a 401 Unauthorized result.
|
static Result |
unauthorized(java.io.File content)
Generates a 401 Unauthorized result.
|
static Result |
unauthorized(java.io.File content,
boolean inline)
Generates a 401 Unauthorized result.
|
static Result |
unauthorized(java.io.File content,
java.lang.String filename)
Generates a 401 Unauthorized result.
|
static Result |
unauthorized(java.io.InputStream content)
Generates a 401 Unauthorized result.
|
static Result |
unauthorized(java.io.InputStream content,
long contentLength)
Generates a 401 Unauthorized result.
|
static Result |
unauthorized(com.fasterxml.jackson.databind.JsonNode content)
Generates a 401 Unauthorized result.
|
static Result |
unauthorized(com.fasterxml.jackson.databind.JsonNode content,
com.fasterxml.jackson.core.JsonEncoding encoding)
Generates a 401 Unauthorized result.
|
static Result |
unauthorized(java.lang.String content)
Generates a 401 Unauthorized result.
|
static Result |
unauthorized(java.lang.String content,
java.lang.String charset)
Generates a 401 Unauthorized result.
|
static StatusHeader |
unsupportedMediaType()
Generates a 415 Unsupported Media Type result.
|
static Result |
unsupportedMediaType(byte[] content)
Generates a 415 Unsupported Media Type result.
|
static Result |
unsupportedMediaType(play.twirl.api.Content content)
Generates a 415 Unsupported Media Type result.
|
static Result |
unsupportedMediaType(play.twirl.api.Content content,
java.lang.String charset)
Generates a 415 Unsupported Media Type result.
|
static Result |
unsupportedMediaType(java.io.File content)
Generates a 415 Unsupported Media Type result.
|
static Result |
unsupportedMediaType(java.io.File content,
boolean inline)
Generates a 415 Unsupported Media Type result.
|
static Result |
unsupportedMediaType(java.io.File content,
java.lang.String filename)
Generates a 415 Unsupported Media Type result.
|
static Result |
unsupportedMediaType(java.io.InputStream content)
Generates a 415 Unsupported Media Type result.
|
static Result |
unsupportedMediaType(java.io.InputStream content,
long contentLength)
Generates a 415 Unsupported Media Type result.
|
static Result |
unsupportedMediaType(com.fasterxml.jackson.databind.JsonNode content)
Generates a 415 Unsupported Media Type result.
|
static Result |
unsupportedMediaType(com.fasterxml.jackson.databind.JsonNode content,
com.fasterxml.jackson.core.JsonEncoding encoding)
Generates a 415 Unsupported Media Type result.
|
static Result |
unsupportedMediaType(java.lang.String content)
Generates a 415 Unsupported Media Type result.
|
static Result |
unsupportedMediaType(java.lang.String content,
java.lang.String charset)
Generates a 415 Unsupported Media Type result.
|
public static StatusHeader status(int status)
status
- the HTTP status for this result e.g. 200 (OK), 404 (NOT_FOUND)public static Result status(int status, play.twirl.api.Content content)
status
- the HTTP status for this result e.g. 200 (OK), 404 (NOT_FOUND)content
- the result's body contentpublic static Result status(int status, play.twirl.api.Content content, java.lang.String charset)
status
- the HTTP status for this result e.g. 200 (OK), 404 (NOT_FOUND)content
- the result's body contentcharset
- the charset to encode the content with (e.g. "UTF-8")public static Result status(int status, java.lang.String content)
status
- the HTTP status for this result e.g. 200 (OK), 404 (NOT_FOUND)content
- the result's body content. It will be encoded as a UTF-8 string.public static Result status(int status, java.lang.String content, java.lang.String charset)
status
- the HTTP status for this result e.g. 200 (OK), 404 (NOT_FOUND)content
- the result's body content.charset
- the charset in which to encode the content (e.g. "UTF-8")public static Result status(int status, com.fasterxml.jackson.databind.JsonNode content)
status
- the HTTP status for this result e.g. 200 (OK), 404 (NOT_FOUND)content
- the result's body content as a play-json objectpublic static Result status(int status, com.fasterxml.jackson.databind.JsonNode content, com.fasterxml.jackson.core.JsonEncoding encoding)
status
- the HTTP status for this result e.g. 200 (OK), 404 (NOT_FOUND)content
- the result's body content, as a play-json objectencoding
- the encoding into which the json should be encodedpublic static Result status(int status, byte[] content)
status
- the HTTP status for this result e.g. 200 (OK), 404 (NOT_FOUND)content
- the result's body content, as a byte arraypublic static Result status(int status, akka.util.ByteString content)
status
- the HTTP status for this result e.g. 200 (OK), 404 (NOT_FOUND)content
- the result's body contentpublic static Result status(int status, java.io.InputStream content)
status
- the HTTP status for this result e.g. 200 (OK), 404 (NOT_FOUND)content
- the input stream containing data to chunk overpublic static Result status(int status, java.io.InputStream content, long contentLength)
status
- the HTTP status for this result e.g. 200 (OK), 404 (NOT_FOUND)content
- the input stream containing data to chunk overcontentLength
- the length of the provided content in bytes.public static Result status(int status, java.io.File content)
status
- the HTTP status for this result e.g. 200 (OK), 404 (NOT_FOUND)content
- the file to sendpublic static Result status(int status, java.io.File content, boolean inline)
status
- the HTTP status for this result e.g. 200 (OK), 404 (NOT_FOUND)content
- the file to sendinline
- true
to have it sent with inline Content-Disposition.public static Result status(int status, java.io.File content, java.lang.String fileName)
status
- the HTTP status for this result e.g. 200 (OK), 404 (NOT_FOUND)content
- the file to sendfileName
- the name that the client should receive this file aspublic static StatusHeader noContent()
public static StatusHeader ok()
public static Result ok(play.twirl.api.Content content)
content
- the HTTP response bodypublic static Result ok(play.twirl.api.Content content, java.lang.String charset)
content
- the HTTP response bodycharset
- the charset into which the content should be encoded (e.g. "UTF-8")public static Result ok(java.lang.String content)
content
- HTTP response body, encoded as a UTF-8 stringpublic static Result ok(java.lang.String content, java.lang.String charset)
content
- the HTTP response bodycharset
- the charset into which the content should be encoded (e.g. "UTF-8")public static Result ok(com.fasterxml.jackson.databind.JsonNode content)
content
- the result's body content as a play-json object. It will be encoded
as a UTF-8 string.public static Result ok(com.fasterxml.jackson.databind.JsonNode content, com.fasterxml.jackson.core.JsonEncoding encoding)
content
- the result's body content as a play-json objectencoding
- the encoding into which the json should be encodedpublic static Result ok(byte[] content)
content
- the result's body contentpublic static Result ok(java.io.InputStream content)
content
- the input stream containing data to chunk overpublic static Result ok(java.io.InputStream content, long contentLength)
content
- the input stream containing data to chunk overcontentLength
- the length of the provided content in bytes.public static Result ok(java.io.File content)
content
- The file to send.public static Result ok(java.io.File content, boolean inline)
content
- The file to send.inline
- Whether the file should be sent inline, or as an attachment.public static Result ok(java.io.File content, java.lang.String filename)
content
- The file to send.filename
- The name to send the file as.public static StatusHeader created()
public static Result created(play.twirl.api.Content content)
content
- the HTTP response bodypublic static Result created(play.twirl.api.Content content, java.lang.String charset)
content
- the HTTP response bodycharset
- the charset into which the content should be encoded (e.g. "UTF-8")public static Result created(java.lang.String content)
content
- HTTP response body, encoded as a UTF-8 stringpublic static Result created(java.lang.String content, java.lang.String charset)
content
- the HTTP response bodycharset
- the charset into which the content should be encoded (e.g. "UTF-8")public static Result created(com.fasterxml.jackson.databind.JsonNode content)
content
- the result's body content as a play-json object. It will be encoded
as a UTF-8 string.public static Result created(com.fasterxml.jackson.databind.JsonNode content, com.fasterxml.jackson.core.JsonEncoding encoding)
content
- the result's body content as a play-json objectencoding
- the encoding into which the json should be encodedpublic static Result created(byte[] content)
content
- the result's body contentpublic static Result created(java.io.InputStream content)
content
- the input stream containing data to chunk overpublic static Result created(java.io.InputStream content, long contentLength)
content
- the input stream containing data to chunk overcontentLength
- the length of the provided content in bytes.public static Result created(java.io.File content)
content
- The file to send.public static Result created(java.io.File content, boolean inline)
content
- The file to send.inline
- Whether the file should be sent inline, or as an attachment.public static Result created(java.io.File content, java.lang.String filename)
content
- The file to send.filename
- The name to send the file as.public static StatusHeader badRequest()
public static Result badRequest(play.twirl.api.Content content)
content
- the HTTP response bodypublic static Result badRequest(play.twirl.api.Content content, java.lang.String charset)
content
- the HTTP response bodycharset
- the charset into which the content should be encoded (e.g. "UTF-8")public static Result badRequest(java.lang.String content)
content
- HTTP response body, encoded as a UTF-8 stringpublic static Result badRequest(java.lang.String content, java.lang.String charset)
content
- the HTTP response bodycharset
- the charset into which the content should be encoded (e.g. "UTF-8")public static Result badRequest(com.fasterxml.jackson.databind.JsonNode content)
content
- the result's body content as a play-json object. It will be encoded
as a UTF-8 string.public static Result badRequest(com.fasterxml.jackson.databind.JsonNode content, com.fasterxml.jackson.core.JsonEncoding encoding)
content
- the result's body content as a play-json objectencoding
- the encoding into which the json should be encodedpublic static Result badRequest(byte[] content)
content
- the result's body contentpublic static Result badRequest(java.io.InputStream content)
content
- the input stream containing data to chunk overpublic static Result badRequest(java.io.InputStream content, long contentLength)
content
- the input stream containing data to chunk overcontentLength
- the length of the provided content in bytes.public static Result badRequest(java.io.File content)
content
- The file to send.public static Result badRequest(java.io.File content, boolean inline)
content
- The file to send.inline
- Whether the file should be sent inline, or as an attachment.public static Result badRequest(java.io.File content, java.lang.String filename)
content
- The file to send.filename
- The name to send the file as.public static StatusHeader unauthorized()
public static Result unauthorized(play.twirl.api.Content content)
content
- the HTTP response bodypublic static Result unauthorized(play.twirl.api.Content content, java.lang.String charset)
content
- the HTTP response bodycharset
- the charset into which the content should be encoded (e.g. "UTF-8")public static Result unauthorized(java.lang.String content)
content
- HTTP response body, encoded as a UTF-8 stringpublic static Result unauthorized(java.lang.String content, java.lang.String charset)
content
- the HTTP response bodycharset
- the charset into which the content should be encoded (e.g. "UTF-8")public static Result unauthorized(com.fasterxml.jackson.databind.JsonNode content)
content
- the result's body content as a play-json object. It will be encoded
as a UTF-8 string.public static Result unauthorized(com.fasterxml.jackson.databind.JsonNode content, com.fasterxml.jackson.core.JsonEncoding encoding)
content
- the result's body content as a play-json objectencoding
- the encoding into which the json should be encodedpublic static Result unauthorized(byte[] content)
content
- the result's body contentpublic static Result unauthorized(java.io.InputStream content)
content
- the input stream containing data to chunk overpublic static Result unauthorized(java.io.InputStream content, long contentLength)
content
- the input stream containing data to chunk overcontentLength
- the length of the provided content in bytes.public static Result unauthorized(java.io.File content)
content
- The file to send.public static Result unauthorized(java.io.File content, boolean inline)
content
- The file to send.inline
- Whether the file should be sent inline, or as an attachment.public static Result unauthorized(java.io.File content, java.lang.String filename)
content
- The file to send.filename
- The name to send the file as.public static StatusHeader paymentRequired()
public static Result paymentRequired(play.twirl.api.Content content)
content
- the HTTP response bodypublic static Result paymentRequired(play.twirl.api.Content content, java.lang.String charset)
content
- the HTTP response bodycharset
- the charset into which the content should be encoded (e.g. "UTF-8")public static Result paymentRequired(java.lang.String content)
content
- HTTP response body, encoded as a UTF-8 stringpublic static Result paymentRequired(java.lang.String content, java.lang.String charset)
content
- the HTTP response bodycharset
- the charset into which the content should be encoded (e.g. "UTF-8")public static Result paymentRequired(com.fasterxml.jackson.databind.JsonNode content)
content
- the result's body content as a play-json object. It will be encoded
as a UTF-8 string.public static Result paymentRequired(com.fasterxml.jackson.databind.JsonNode content, com.fasterxml.jackson.core.JsonEncoding encoding)
content
- the result's body content as a play-json objectencoding
- the encoding into which the json should be encodedpublic static Result paymentRequired(byte[] content)
content
- the result's body contentpublic static Result paymentRequired(java.io.InputStream content)
content
- the input stream containing data to chunk overpublic static Result paymentRequired(java.io.InputStream content, long contentLength)
content
- the input stream containing data to chunk overcontentLength
- the length of the provided content in bytes.public static Result paymentRequired(java.io.File content)
content
- The file to send.public static Result paymentRequired(java.io.File content, boolean inline)
content
- The file to send.inline
- Whether the file should be sent inline, or as an attachment.public static Result paymentRequired(java.io.File content, java.lang.String filename)
content
- The file to send.filename
- The name to send the file as.public static StatusHeader forbidden()
public static Result forbidden(play.twirl.api.Content content)
content
- the HTTP response bodypublic static Result forbidden(play.twirl.api.Content content, java.lang.String charset)
content
- the HTTP response bodycharset
- the charset into which the content should be encoded (e.g. "UTF-8")public static Result forbidden(java.lang.String content)
content
- HTTP response body, encoded as a UTF-8 stringpublic static Result forbidden(java.lang.String content, java.lang.String charset)
content
- the HTTP response bodycharset
- the charset into which the content should be encoded (e.g. "UTF-8")public static Result forbidden(com.fasterxml.jackson.databind.JsonNode content)
content
- the result's body content as a play-json object. It will be encoded
as a UTF-8 string.public static Result forbidden(com.fasterxml.jackson.databind.JsonNode content, com.fasterxml.jackson.core.JsonEncoding encoding)
content
- the result's body content as a play-json objectencoding
- the encoding into which the json should be encodedpublic static Result forbidden(byte[] content)
content
- the result's body contentpublic static Result forbidden(java.io.InputStream content)
content
- the input stream containing data to chunk overpublic static Result forbidden(java.io.InputStream content, long contentLength)
content
- the input stream containing data to chunk overcontentLength
- the length of the provided content in bytes.public static Result forbidden(java.io.File content)
content
- The file to send.public static Result forbidden(java.io.File content, boolean inline)
content
- The file to send.inline
- Whether the file should be sent inline, or as an attachment.public static Result forbidden(java.io.File content, java.lang.String filename)
content
- The file to send.filename
- The name to send the file as.public static StatusHeader notFound()
public static Result notFound(play.twirl.api.Content content)
content
- the HTTP response bodypublic static Result notFound(play.twirl.api.Content content, java.lang.String charset)
content
- the HTTP response bodycharset
- the charset into which the content should be encoded (e.g. "UTF-8")public static Result notFound(java.lang.String content)
content
- HTTP response body, encoded as a UTF-8 stringpublic static Result notFound(java.lang.String content, java.lang.String charset)
content
- the HTTP response bodycharset
- the charset into which the content should be encoded (e.g. "UTF-8")public static Result notFound(com.fasterxml.jackson.databind.JsonNode content)
content
- the result's body content as a play-json object. It will be encoded
as a UTF-8 string.public static Result notFound(com.fasterxml.jackson.databind.JsonNode content, com.fasterxml.jackson.core.JsonEncoding encoding)
content
- the result's body content as a play-json objectencoding
- the encoding into which the json should be encodedpublic static Result notFound(byte[] content)
content
- the result's body contentpublic static Result notFound(java.io.InputStream content)
content
- the input stream containing data to chunk overpublic static Result notFound(java.io.InputStream content, long contentLength)
content
- the input stream containing data to chunk overcontentLength
- the length of the provided content in bytes.public static Result notFound(java.io.File content)
content
- The file to send.public static Result notFound(java.io.File content, boolean inline)
content
- The file to send.inline
- Whether the file should be sent inline, or as an attachment.public static Result notFound(java.io.File content, java.lang.String filename)
content
- The file to send.filename
- The name to send the file as.public static StatusHeader notAcceptable()
public static Result notAcceptable(play.twirl.api.Content content)
content
- the HTTP response bodypublic static Result notAcceptable(play.twirl.api.Content content, java.lang.String charset)
content
- the HTTP response bodycharset
- the charset into which the content should be encoded (e.g. "UTF-8")public static Result notAcceptable(java.lang.String content)
content
- HTTP response body, encoded as a UTF-8 stringpublic static Result notAcceptable(java.lang.String content, java.lang.String charset)
content
- the HTTP response bodycharset
- the charset into which the content should be encoded (e.g. "UTF-8")public static Result notAcceptable(com.fasterxml.jackson.databind.JsonNode content)
content
- the result's body content as a play-json object. It will be encoded
as a UTF-8 string.public static Result notAcceptable(com.fasterxml.jackson.databind.JsonNode content, com.fasterxml.jackson.core.JsonEncoding encoding)
content
- the result's body content as a play-json objectencoding
- the encoding into which the json should be encodedpublic static Result notAcceptable(byte[] content)
content
- the result's body contentpublic static Result notAcceptable(java.io.InputStream content)
content
- the input stream containing data to chunk overpublic static Result notAcceptable(java.io.InputStream content, long contentLength)
content
- the input stream containing data to chunk overcontentLength
- the length of the provided content in bytes.public static Result notAcceptable(java.io.File content)
content
- The file to send.public static Result notAcceptable(java.io.File content, boolean inline)
content
- The file to send.inline
- Whether the file should be sent inline, or as an attachment.public static Result notAcceptable(java.io.File content, java.lang.String filename)
content
- The file to send.filename
- The name to send the file as.public static StatusHeader unsupportedMediaType()
public static Result unsupportedMediaType(play.twirl.api.Content content)
content
- the HTTP response bodypublic static Result unsupportedMediaType(play.twirl.api.Content content, java.lang.String charset)
content
- the HTTP response bodycharset
- the charset into which the content should be encoded (e.g. "UTF-8")public static Result unsupportedMediaType(java.lang.String content)
content
- HTTP response body, encoded as a UTF-8 stringpublic static Result unsupportedMediaType(java.lang.String content, java.lang.String charset)
content
- the HTTP response bodycharset
- the charset into which the content should be encoded (e.g. "UTF-8")public static Result unsupportedMediaType(com.fasterxml.jackson.databind.JsonNode content)
content
- the result's body content as a play-json object. It will be encoded
as a UTF-8 string.public static Result unsupportedMediaType(com.fasterxml.jackson.databind.JsonNode content, com.fasterxml.jackson.core.JsonEncoding encoding)
content
- the result's body content as a play-json objectencoding
- the encoding into which the json should be encodedpublic static Result unsupportedMediaType(byte[] content)
content
- the result's body contentpublic static Result unsupportedMediaType(java.io.InputStream content)
content
- the input stream containing data to chunk overpublic static Result unsupportedMediaType(java.io.InputStream content, long contentLength)
content
- the input stream containing data to chunk overcontentLength
- the length of the provided content in bytes.public static Result unsupportedMediaType(java.io.File content)
content
- The file to send.public static Result unsupportedMediaType(java.io.File content, boolean inline)
content
- The file to send.inline
- Whether the file should be sent inline, or as an attachment.public static Result unsupportedMediaType(java.io.File content, java.lang.String filename)
content
- The file to send.filename
- The name to send the file as.public static StatusHeader internalServerError()
public static Result internalServerError(play.twirl.api.Content content)
content
- the HTTP response bodypublic static Result internalServerError(play.twirl.api.Content content, java.lang.String charset)
content
- the HTTP response bodycharset
- the charset into which the content should be encoded (e.g. "UTF-8")public static Result internalServerError(java.lang.String content)
content
- HTTP response body, encoded as a UTF-8 stringpublic static Result internalServerError(java.lang.String content, java.lang.String charset)
content
- the HTTP response bodycharset
- the charset into which the content should be encoded (e.g. "UTF-8")public static Result internalServerError(com.fasterxml.jackson.databind.JsonNode content)
content
- the result's body content as a play-json object. It will be encoded
as a UTF-8 string.public static Result internalServerError(com.fasterxml.jackson.databind.JsonNode content, com.fasterxml.jackson.core.JsonEncoding encoding)
content
- the result's body content as a play-json objectencoding
- the encoding into which the json should be encodedpublic static Result internalServerError(byte[] content)
content
- the result's body contentpublic static Result internalServerError(java.io.InputStream content)
content
- the input stream containing data to chunk overpublic static Result internalServerError(java.io.InputStream content, long contentLength)
content
- the input stream containing data to chunk overcontentLength
- the length of the provided content in bytes.public static Result internalServerError(java.io.File content)
content
- The file to send.public static Result internalServerError(java.io.File content, boolean inline)
content
- The file to send.inline
- Whether the file should be sent inline, or as an attachment.public static Result internalServerError(java.io.File content, java.lang.String filename)
content
- The file to send.filename
- The name to send the file as.public static Result movedPermanently(java.lang.String url)
url
- The url to redirect.public static Result movedPermanently(Call call)
call
- Call defining the url to redirect (typically comes from reverse router).public static Result found(java.lang.String url)
url
- The url to redirect.public static Result found(Call call)
call
- Call defining the url to redirect (typically comes from reverse router).public static Result seeOther(java.lang.String url)
url
- The url to redirect.public static Result seeOther(Call call)
call
- Call defining the url to redirect (typically comes from reverse router).public static Result redirect(java.lang.String url)
url
- The url to redirect.public static Result redirect(Call call)
call
- Call defining the url to redirect (typically comes from reverse router).public static Result temporaryRedirect(java.lang.String url)
url
- The url to redirect.public static Result temporaryRedirect(Call call)
call
- Call defining the url to redirect (typically comes from reverse router).public static Result permanentRedirect(java.lang.String url)
url
- The url to redirect.