class ByteArrayContent : ByteArrayContent
Implementation of the OutgoingContent.ByteArrayContent for sending array of bytes |
|
data class CachingOptions
Specifies caching properties for an OutgoingContent such as Cache-Control or Expires |
|
class ChannelWriterContent : WriteChannelContent
OutgoingContent to respond with ByteWriteChannel. The stream would be automatically closed after body finish. |
|
data class EntityTagVersion : Version
This version checks etag value and pass it through conditions supplied by the remote client. Depending on conditions it produces return value of enum type VersionCheckResult |
|
data class LastModifiedVersion : Version
This version passes the given lastModified date through the client provided http conditional headers If-Modified-Since and If-Unmodified-Since. |
|
interface MultiPartData
Represents a multipart data stream that could be received from a call |
|
sealed class OutgoingContent
Information about the content to be sent to the peer, recognized by a client or server engine |
|
class OutputStreamContent : WriteChannelContent
OutgoingContent to respond with OutputStream. The stream would be automatically closed after body finish. |
|
sealed class PartData
Represents a multipart/form-data entry. Could be a FormItem or FileItem |
|
class TextContent : ByteArrayContent
Represents a text content that could be sent |
|
class URIFileContent : ReadChannelContent
Represents a content that is served from the specified uri |
|
interface Version
Represents content version |
|
enum class VersionCheckResult
Represent result of the version comparison between content being sent and HTTP request. |
|
class WriterContent : WriteChannelContent
Represents a content that is produced by body function |
val CachingProperty: AttributeKey<CachingOptions>
Specifies a key for CacheControl extension property for OutgoingContent |
|
val VersionListProperty: AttributeKey<List<Version>>
Specifies a key for VersionList extension property for OutgoingContent |
|
var OutgoingContent.caching: CachingOptions?
Gets or sets CacheControl instance as an extension property on this content |
|
val FileItem.streamProvider: () -> InputStream
Provides file item's content as an InputStream |
|
var OutgoingContent.versions: List<Version>
Gets or sets list of Version instances as an extension property on this content |
fun EntityTagVersion(spec: String): EntityTagVersion
Creates an instance of EntityTagVersion parsing the spec via EntityTagVersion.parseSingle. |
|
suspend fun MultiPartData.forEachPart(partHandler: suspend (PartData) -> Unit): Unit
Parse multipart data stream and invoke partHandler for each PartData encountered |
|
suspend fun MultiPartData.readAllParts(): List<PartData>
Parse multipart data stream and put all parts into a list |