object HttpEntity
- Alphabetic
- By Inheritance
- HttpEntity
- AnyRef
- Any
- Hide All
- Show All
- Public
- Protected
Type Members
- final case class Chunk(data: ByteString, extension: String = "") extends ChunkStreamPart with Product with Serializable
An intermediate entity chunk guaranteed to carry non-empty data.
- sealed abstract class ChunkStreamPart extends javadsl.model.HttpEntity.ChunkStreamPart
An element of the HttpEntity data stream.
An element of the HttpEntity data stream. Can be either a
Chunk
or aLastChunk
. - final case class Chunked(contentType: ContentType, chunks: Source[ChunkStreamPart, Any]) extends javadsl.model.HttpEntity.Chunked with MessageEntity with Product with Serializable
The model for the entity of a chunked HTTP message (with
Transfer-Encoding: chunked
). - final case class CloseDelimited(contentType: ContentType, data: Source[ByteString, Any]) extends javadsl.model.HttpEntity.CloseDelimited with ResponseEntity with WithoutKnownLength with Product with Serializable
The model for the entity of an HTTP response that is terminated by the server closing the connection.
The model for the entity of an HTTP response that is terminated by the server closing the connection. The content-length of such responses is unknown at the time the response headers have been received. Note that this type of HttpEntity can only be used for HttpResponses.
- final case class Default(contentType: ContentType, contentLength: Long, data: Source[ByteString, Any]) extends javadsl.model.HttpEntity.Default with UniversalEntity with Product with Serializable
The model for the entity of a "regular" unchunked HTTP message with a known non-zero length.
- final class DiscardedEntity extends javadsl.model.HttpMessage.DiscardedEntity
Represents the currently being-drained HTTP Entity which triggers completion of the contained Future once the entity has been drained for the given HttpMessage completely.
- implicit final class HttpEntityScalaDSLSugar extends AnyVal
Adds Scala DSL idiomatic methods to HttpEntity, e.g.
Adds Scala DSL idiomatic methods to HttpEntity, e.g. versions of methods with an implicit Materializer.
- final case class IndefiniteLength(contentType: ContentType, data: Source[ByteString, Any]) extends javadsl.model.HttpEntity.IndefiniteLength with BodyPartEntity with WithoutKnownLength with Product with Serializable
The model for the entity of a BodyPart with an indefinite length.
The model for the entity of a BodyPart with an indefinite length. Note that this type of HttpEntity can only be used for BodyParts.
- case class LastChunk(extension: String = "", trailer: Seq[HttpHeader] = Nil) extends ChunkStreamPart with Product with Serializable
The final chunk of a chunk stream.
The final chunk of a chunk stream. If you don't need extensions or trailer headers you can save an allocation by directly using the
LastChunk
companion object. - final case class Strict(contentType: ContentType, data: ByteString) extends javadsl.model.HttpEntity.Strict with UniversalEntity with Product with Serializable
The model for the entity of a "regular" unchunked HTTP message with known, fixed data.
Value Members
- final def !=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def ##: Int
- Definition Classes
- AnyRef → Any
- final def ==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- val Empty: Strict
- def apply(contentType: ContentType, data: Source[ByteString, Any]): Chunked
- def apply(contentType: ContentType, contentLength: Long, data: Source[ByteString, Any]): UniversalEntity
- def apply(contentType: ContentType, data: ByteString): Strict
- def apply(contentType: ContentType, bytes: Array[Byte]): Strict
- def apply(contentType: WithFixedCharset, string: String): Strict
- def apply(contentType: NonBinary, string: String): Strict
- implicit def apply(data: ByteString): Strict
- implicit def apply(bytes: Array[Byte]): Strict
- implicit def apply(string: String): Strict
- final def asInstanceOf[T0]: T0
- Definition Classes
- Any
- def clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.CloneNotSupportedException]) @native()
- def empty(contentType: ContentType): Strict
- final def eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- def equals(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef → Any
- def finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.Throwable])
- def fromFile(contentType: ContentType, file: File, chunkSize: Int = -1): UniversalEntity
Returns either the empty entity, if the given file is empty, or a HttpEntity.Default entity consisting of a stream of pekko.util.ByteString instances each containing
chunkSize
bytes (except for the final ByteString, which simply contains the remaining bytes).Returns either the empty entity, if the given file is empty, or a HttpEntity.Default entity consisting of a stream of pekko.util.ByteString instances each containing
chunkSize
bytes (except for the final ByteString, which simply contains the remaining bytes).If the given
chunkSize
is -1 the default chunk size is used. - def fromPath(contentType: ContentType, file: Path, chunkSize: Int = -1): UniversalEntity
Returns either the empty entity, if the given file is empty, or a HttpEntity.Default entity consisting of a stream of pekko.util.ByteString instances each containing
chunkSize
bytes (except for the final ByteString, which simply contains the remaining bytes).Returns either the empty entity, if the given file is empty, or a HttpEntity.Default entity consisting of a stream of pekko.util.ByteString instances each containing
chunkSize
bytes (except for the final ByteString, which simply contains the remaining bytes).If the given
chunkSize
is -1 the default chunk size is used. - final def getClass(): Class[_ <: AnyRef]
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
- def hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
- final def isInstanceOf[T0]: Boolean
- Definition Classes
- Any
- final def ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- final def notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
- final def notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
- final def synchronized[T0](arg0: => T0): T0
- Definition Classes
- AnyRef
- def toString(): String
- Definition Classes
- AnyRef → Any
- final def wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException]) @native()
- object Chunk extends Serializable
- object ChunkStreamPart
- object Chunked extends Serializable
- object LastChunk extends LastChunk
Deprecated Value Members
- def limitableByteSource[Mat](source: Source[ByteString, Mat]): Source[ByteString, Mat]
Deprecated: no-op, not explicitly needed any more.
Deprecated: no-op, not explicitly needed any more.
- Annotations
- @deprecated
- Deprecated
(Since version Akka HTTP 10.1.5) Not needed explicitly any more.
- def limitableChunkSource[Mat](source: Source[ChunkStreamPart, Mat]): Source[ChunkStreamPart, Mat]
Deprecated: no-op, not explicitly needed any more.
Deprecated: no-op, not explicitly needed any more.
- Annotations
- @deprecated
- Deprecated
(Since version Akka HTTP 10.1.5) Not needed explicitly any more.