public static final class HttpEntity.Chunked extends HttpEntity
HttpEntity.Chunked, HttpEntity.Streamed, HttpEntity.Strict
NO_ENTITY
Constructor and Description |
---|
Chunked(akka.stream.javadsl.Source<play.api.http.HttpChunk,?> chunks,
java.util.Optional<java.lang.String> contentType) |
Modifier and Type | Method and Description |
---|---|
HttpEntity |
as(java.lang.String contentType)
Return the entity as the given content type.
|
play.api.http.HttpEntity |
asScala() |
akka.stream.javadsl.Source<play.api.http.HttpChunk,?> |
chunks() |
java.util.Optional<java.lang.Long> |
contentLength()
The content length, if known
|
java.util.Optional<java.lang.String> |
contentType()
The content type, if defined
|
akka.stream.javadsl.Source<akka.util.ByteString,?> |
dataStream()
The stream of data.
|
boolean |
isKnownEmpty()
Whether the entity is known to be empty or not.
|
chunked, consumeData, fromContent, fromString
public Chunked(akka.stream.javadsl.Source<play.api.http.HttpChunk,?> chunks, java.util.Optional<java.lang.String> contentType)
public akka.stream.javadsl.Source<play.api.http.HttpChunk,?> chunks()
public java.util.Optional<java.lang.String> contentType()
HttpEntity
contentType
in class HttpEntity
public boolean isKnownEmpty()
HttpEntity
isKnownEmpty
in class HttpEntity
public java.util.Optional<java.lang.Long> contentLength()
HttpEntity
contentLength
in class HttpEntity
public HttpEntity as(java.lang.String contentType)
HttpEntity
as
in class HttpEntity
public akka.stream.javadsl.Source<akka.util.ByteString,?> dataStream()
HttpEntity
dataStream
in class HttpEntity
public play.api.http.HttpEntity asScala()
asScala
in class HttpEntity