Package 

Class JsonUtils

    • Method Summary

      Modifier and Type Method Description
      final static Map<String, Object> toMap(JSONObject $self) Extension function for JSONObject to convert it to a Kotlin Map.
      final static Map<String, String> toStringMap(JSONObject $self) Extension function for JSONObject to convert it to a Map with String values.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Method Detail

      • toMap

         final static Map<String, Object> toMap(JSONObject $self)

        Extension function for JSONObject to convert it to a Kotlin Map. Recursively converts all nested JSONObjects and JSONArrays into Maps and Lists respectively.

      • toStringMap

         final static Map<String, String> toStringMap(JSONObject $self)

        Extension function for JSONObject to convert it to a Map with String values. All JSON values are converted to their string representation.