InternalKrosstalkResponse

class InternalKrosstalkResponse(statusCode: Int, headers: Headers, body: ByteArray, stringBody: () -> String?)

The response to a Krosstalk request.

Parameters

stringBody

a lambda to get the body as a string, or null if not possible. Will likely use the response's charset header

Constructors

Link copied to clipboard
fun InternalKrosstalkResponse(statusCode: Int, headers: Headers, body: ByteArray, stringBody: () -> String?)

Properties

Link copied to clipboard
val body: ByteArray

the response body

Link copied to clipboard
val headers: Headers

the response headers

Link copied to clipboard
val statusCode: Int

the http status code of the response

Link copied to clipboard
val stringBody: String?

the body as a string, or null if not possible or the body is empty. Calculated using the stringBody parameter.

Sources

Link copied to clipboard