-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description public final classJSONKtor.JSONReceiveCoroutineContextA CoroutineContext for Channel deserialization coroutines.
-
Constructor Summary
Constructors Constructor Description JSONKtor(ContentType contentType, JSONConfig config)
-
Method Summary
Modifier and Type Method Description OutgoingContentserializeNullable(ContentType contentType, Charset charset, TypeInfo typeInfo, Object value)Serialize output object to an OutgoingContent. Objectdeserialize(Charset charset, TypeInfo typeInfo, ByteReadChannel content)Deserialize JSON input to a specified type. -
-
Method Detail
-
serializeNullable
OutgoingContent serializeNullable(ContentType contentType, Charset charset, TypeInfo typeInfo, Object value)
Serialize output object to an OutgoingContent. Creates a WriteChannelContent (streaming) if the
streamOutputflag is set in the JSONConfig, otherwise creates a TextContent (non-streaming).
-
deserialize
Object deserialize(Charset charset, TypeInfo typeInfo, ByteReadChannel content)
Deserialize JSON input to a specified type. If the top-level type is a Channel or a Flow, the object is returned immediately and the data is streamed asynchronously into it.
-
-
-
-