ReadChannelContent

abstract class ReadChannelContent : OutgoingContent

Variant of a OutgoingContent with payload read from ByteReadChannel

Constructors

Link copied to clipboard
fun ReadChannelContent()

Functions

Link copied to clipboard
open fun <T : Any> getProperty(key: AttributeKey<T>): T?

Gets an extension property for this content

Link copied to clipboard
abstract fun readFrom(): ByteReadChannel

Provides ByteReadChannel for the content

open fun readFrom(range: LongRange): ByteReadChannel

Provides ByteReadChannel for the given range of the content

Link copied to clipboard
open fun <T : Any> setProperty(key: AttributeKey<T>, value: T?)

Sets an extension property for this content

Link copied to clipboard
open fun trailers(): Headers?

Trailers to set when sending this content, will be ignored if request is not in HTTP2 mode

Properties

Link copied to clipboard
open val contentLength: Long?

Specifies content length in bytes for this resource.

Link copied to clipboard
open val contentType: ContentType?

Specifies ContentType for this resource.

Link copied to clipboard
open val headers: Headers

Headers to set when sending this content

Link copied to clipboard
open val status: HttpStatusCode?

Status code to set when sending this content

Inheritors

Link copied to clipboard