abstract class WriteChannelContent : OutgoingContent
Variant of a OutgoingContent with payload written to ByteWriteChannel
WriteChannelContent()
Variant of a OutgoingContent with payload written to ByteWriteChannel |
open val contentLength: Long?
Specifies content length in bytes for this resource. |
|
open val contentType: ContentType?
Specifies ContentType for this resource. |
|
open val headers: Headers
Headers to set when sending this content |
|
open val status: HttpStatusCode?
Status code to set when sending this content |
abstract suspend fun writeTo(channel: ByteWriteChannel): Unit
Receives channel provided by the engine and writes all data to it |
open fun <T : Any> getProperty(key: AttributeKey<T>): T?
Gets an extension property for this content |
|
open fun <T : Any> setProperty(key: AttributeKey<T>, value: T?): Unit
Sets an extension property for this content |
class ChannelWriterContent : WriteChannelContent
OutgoingContent to respond with ByteWriteChannel. The stream would be automatically closed after body finish. |
|
class OutputStreamContent : WriteChannelContent
OutgoingContent to respond with OutputStream. The stream would be automatically closed after body finish. |
|
class WriterContent : WriteChannelContent
Represents a content that is produced by body function |