FusJsonSerializer

JSON serialization abstraction used by the FUS client. Implementations can delegate to different JSON libraries.

Functions

Link copied to clipboard
open suspend fun close()

Called when FusClient is closed.

Link copied to clipboard
abstract fun <T : Any> fromJson(json: String, clazz: KClass<T>): T

Deserializes the given JSON string into an object of the specified type.

Link copied to clipboard
abstract fun toJson(data: Any, prettyPrint: Boolean = false): String

Serializes the given data object into a JSON string.