Types

Link copied to clipboard
object Companion

Properties

Link copied to clipboard
abstract val body: Body
Link copied to clipboard
abstract val headers: Headers
Link copied to clipboard
abstract val status: Status
Link copied to clipboard
abstract val version: String

Functions

Link copied to clipboard
abstract override fun body(body: String): Response
abstract override fun body(body: Body): Response
abstract override fun body(body: InputStream, length: Long?): Response

(Copy &) sets the body content.

Link copied to clipboard
open fun bodyString(): String

This will realise any underlying stream.

Link copied to clipboard
open override fun close()

Closes the request. For server generated messages, this is called by all backend/client implementations, but when consuming external responses in streaming mode, this should be used.

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
open fun header(name: String): String?

Retrieves the first header value with this name.

abstract override fun header(name: String, value: String?): Response

(Copy &) Adds a header value with this name.

Link copied to clipboard
abstract override fun headers(headers: Headers): Response

(Copy &) Add all passed headers.

Link copied to clipboard
open fun headerValues(name: String): List<String?>

Retrieves all header values with this name.

Link copied to clipboard
Link copied to clipboard
fun Response.invalidateCookie(name: String, domain: String? = null): Response
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
abstract override fun removeHeader(name: String): Response

(Copy &) remove headers with this name.

Link copied to clipboard
abstract override fun removeHeaders(prefix: String): Response

(Copy &) remove headers with this prefix. Default removes all headers.

Link copied to clipboard
Link copied to clipboard
abstract override fun replaceHeader(name: String, value: String?): Response

(Copy &) Adds a header value with this name, replacing any previously set values.

Link copied to clipboard
abstract override fun replaceHeaders(source: Headers): Response

Replace all headers with ones passed.

Link copied to clipboard
Link copied to clipboard
abstract fun status(new: Status): Response
Link copied to clipboard
open override fun toMessage(): String

Returns a formatted wire representation of this message.

Link copied to clipboard
fun Response.transferTo(destination: HttpServletResponse)
fun Response.transferTo(destination: HttpServletResponse)
Link copied to clipboard