toMap

inline fun <T> T.toMap(): JsonObject

Converts a serializable object to a JSON object.