KotlinxSerializer

class KotlinxSerializer : JsonSerializer

A JsonSerializer implemented for kotlinx Serializable classes.

Constructors

<init>

KotlinxSerializer(json: Json = DefaultJson)

A JsonSerializer implemented for kotlinx Serializable classes.

Functions

read

fun read(type: TypeInfo, body: Input): Any

Read content from response using information specified in type.

write

fun write(
    data: Any,
    contentType: ContentType
): OutgoingContent

Convert data object to OutgoingContent.

Inherited Functions

write

open fun write(data: Any): OutgoingContent

Convert data object to OutgoingContent.

Companion Object Properties

DefaultJson

val DefaultJson: Json

DefaultJsonConfiguration

val DefaultJsonConfiguration: Json

Default Json configuration for KotlinxSerializer.