public class RangeResults
extends java.lang.Object
For reference, see RFC 7233.
Constructor and Description |
---|
RangeResults() |
Modifier and Type | Method and Description |
---|---|
static Result |
ofFile(java.io.File file)
Deprecated.
Deprecated as of 2.7.0. Use
ofFile(Http.Request, File) instead. |
static Result |
ofFile(java.io.File file,
java.lang.String fileName)
Deprecated.
Deprecated as of 2.7.0. Use
ofFile(Http.Request, File, String) instead. |
static Result |
ofFile(Http.Request request,
java.io.File file)
Returns the file as a result considering "Range" header.
|
static Result |
ofFile(Http.Request request,
java.io.File file,
FileMimeTypes fileMimeTypes)
Returns the file as a result considering "Range" header.
|
static Result |
ofFile(Http.Request request,
java.io.File file,
java.lang.String fileName)
Returns the file as a result considering "Range" header.
|
static Result |
ofFile(Http.Request request,
java.io.File file,
java.lang.String fileName,
FileMimeTypes fileMimeTypes)
Returns the file as a result considering "Range" header.
|
static Result |
ofPath(Http.Request request,
java.nio.file.Path path)
Returns the path as a result considering "Range" header.
|
static Result |
ofPath(Http.Request request,
java.nio.file.Path path,
FileMimeTypes fileMimeTypes)
Returns the path as a result considering "Range" header.
|
static Result |
ofPath(Http.Request request,
java.nio.file.Path path,
java.lang.String fileName)
Returns the path as a result considering "Range" header.
|
static Result |
ofPath(Http.Request request,
java.nio.file.Path path,
java.lang.String fileName,
FileMimeTypes fileMimeTypes)
Returns the path as a result considering "Range" header.
|
static Result |
ofPath(java.nio.file.Path path)
Deprecated.
Deprecated as of 2.7.0. Use
ofPath(Http.Request, Path) instead. |
static Result |
ofPath(java.nio.file.Path path,
java.lang.String fileName)
Deprecated.
Deprecated as of 2.7.0. Use {link
ofPath(Http.Request, Path, String)
instead. |
static Result |
ofSource(Http.Request request,
java.lang.Long entityLength,
akka.stream.javadsl.Source<akka.util.ByteString,?> source,
java.lang.String fileName,
java.lang.String contentType)
Returns the stream as a result considering "Range" header.
|
static Result |
ofSource(java.lang.Long entityLength,
akka.stream.javadsl.Source<akka.util.ByteString,?> source,
java.lang.String fileName,
java.lang.String contentType)
Deprecated.
Deprecated as of 2.7.0. Use
ofSource(Http.Request, Long, Source, String,
String) instead. |
static Result |
ofStream(Http.Request request,
java.io.InputStream stream)
Returns the stream as a result considering "Range" header.
|
static Result |
ofStream(Http.Request request,
java.io.InputStream stream,
long contentLength)
Returns the stream as a result considering "Range" header.
|
static Result |
ofStream(Http.Request request,
java.io.InputStream stream,
long contentLength,
java.lang.String filename)
Returns the stream as a result considering "Range" header.
|
static Result |
ofStream(Http.Request request,
java.io.InputStream stream,
long contentLength,
java.lang.String filename,
java.lang.String contentType)
Returns the stream as a result considering "Range" header.
|
static Result |
ofStream(java.io.InputStream stream)
Deprecated.
Deprecated as of 2.7.0. Use
ofStream(Http.Request, InputStream) instead. |
static Result |
ofStream(java.io.InputStream stream,
long contentLength)
Deprecated.
Deprecated as of 2.7.0. Use
ofStream(Http.Request, InputStream, long)
instead. |
static Result |
ofStream(java.io.InputStream stream,
long contentLength,
java.lang.String filename)
Deprecated.
Deprecated as of 2.7.0. Use
ofStream(Http.Request, InputStream, long,
String) instead. |
static Result |
ofStream(java.io.InputStream stream,
long contentLength,
java.lang.String filename,
java.lang.String contentType)
Deprecated.
Deprecated as of 2.7.0. Use
ofStream(Http.Request, InputStream, long,
String, String) instead. |
@Deprecated public static Result ofStream(java.io.InputStream stream)
ofStream(Http.Request, InputStream)
instead.stream
- the content streampublic static Result ofStream(Http.Request request, java.io.InputStream stream)
request
- the request from which to retrieve the range header.stream
- the content stream@Deprecated public static Result ofStream(java.io.InputStream stream, long contentLength)
ofStream(Http.Request, InputStream, long)
instead.stream
- the content streamcontentLength
- the entity lengthpublic static Result ofStream(Http.Request request, java.io.InputStream stream, long contentLength)
request
- the request from which to retrieve the range header.stream
- the content streamcontentLength
- the entity length@Deprecated public static Result ofStream(java.io.InputStream stream, long contentLength, java.lang.String filename)
ofStream(Http.Request, InputStream, long,
String)
instead.stream
- the content streamcontentLength
- the entity lengthfilename
- filename used at the Content-Disposition headerpublic static Result ofStream(Http.Request request, java.io.InputStream stream, long contentLength, java.lang.String filename)
request
- the request from which to retrieve the range header.stream
- the content streamcontentLength
- the entity lengthfilename
- filename used at the Content-Disposition header@Deprecated public static Result ofStream(java.io.InputStream stream, long contentLength, java.lang.String filename, java.lang.String contentType)
ofStream(Http.Request, InputStream, long,
String, String)
instead.stream
- the content streamcontentLength
- the entity lengthfilename
- filename used at the Content-Disposition headercontentType
- the content type for this streampublic static Result ofStream(Http.Request request, java.io.InputStream stream, long contentLength, java.lang.String filename, java.lang.String contentType)
request
- the request from which to retrieve the range header.stream
- the content streamcontentLength
- the entity lengthfilename
- filename used at the Content-Disposition headercontentType
- the content type for this stream@Deprecated public static Result ofPath(java.nio.file.Path path)
ofPath(Http.Request, Path)
instead.path
- the content pathpublic static Result ofPath(Http.Request request, java.nio.file.Path path)
request
- the request from which to retrieve the range header.path
- the content pathpublic static Result ofPath(Http.Request request, java.nio.file.Path path, FileMimeTypes fileMimeTypes)
request
- the request from which to retrieve the range header.path
- the content pathfileMimeTypes
- Used for file type mapping.@Deprecated public static Result ofPath(java.nio.file.Path path, java.lang.String fileName)
ofPath(Http.Request, Path, String)
instead.path
- the content pathfileName
- filename used at the Content-Disposition header.public static Result ofPath(Http.Request request, java.nio.file.Path path, java.lang.String fileName)
request
- the request from which to retrieve the range header.path
- the content pathfileName
- filename used at the Content-Disposition header.public static Result ofPath(Http.Request request, java.nio.file.Path path, java.lang.String fileName, FileMimeTypes fileMimeTypes)
request
- the request from which to retrieve the range header.path
- the content pathfileName
- filename used at the Content-Disposition header.fileMimeTypes
- Used for file type mapping.@Deprecated public static Result ofFile(java.io.File file)
ofFile(Http.Request, File)
instead.file
- the content filepublic static Result ofFile(Http.Request request, java.io.File file)
request
- the request from which to retrieve the range header.file
- the content filepublic static Result ofFile(Http.Request request, java.io.File file, FileMimeTypes fileMimeTypes)
request
- the request from which to retrieve the range header.file
- the content filefileMimeTypes
- Used for file type mapping.@Deprecated public static Result ofFile(java.io.File file, java.lang.String fileName)
ofFile(Http.Request, File, String)
instead.file
- the content filefileName
- filename used at the Content-Disposition headerpublic static Result ofFile(Http.Request request, java.io.File file, java.lang.String fileName)
request
- the request from which to retrieve the range header.file
- the content filefileName
- filename used at the Content-Disposition headerpublic static Result ofFile(Http.Request request, java.io.File file, java.lang.String fileName, FileMimeTypes fileMimeTypes)
request
- the request from which to retrieve the range header.file
- the content filefileName
- filename used at the Content-Disposition headerfileMimeTypes
- Used for file type mapping.@Deprecated public static Result ofSource(java.lang.Long entityLength, akka.stream.javadsl.Source<akka.util.ByteString,?> source, java.lang.String fileName, java.lang.String contentType)
ofSource(Http.Request, Long, Source, String,
String)
instead.entityLength
- the entityLengthsource
- source of the entityfileName
- filename used at the Content-Disposition headercontentType
- the content type for this streampublic static Result ofSource(Http.Request request, java.lang.Long entityLength, akka.stream.javadsl.Source<akka.util.ByteString,?> source, java.lang.String fileName, java.lang.String contentType)
request
- the request from which to retrieve the range header.entityLength
- the entityLengthsource
- source of the entityfileName
- filename used at the Content-Disposition headercontentType
- the content type for this stream