buildJsonObject
Builds JsonObject with the given builderAction builder. Example of usage:
val json = buildJsonObject {
put("booleanKey", true)
putJsonArray("arrayKey") {
for (i in 1..10) add(i)
}
putJsonObject("objectKey") {
put("stringKey", "stringValue")
}
}
Content copied to clipboard