So I have a Map in Scala like this:
val m = Map[String, String]( "a" -> "theA", "b" -> "theB", "c" -> "theC", "d" -> "theD", "e" -> "theE" )
and I want to serialize this structure into a JSON string using lift-json.
Do any of you know how to do this?
If you are using the latest Scala 2.10.x and above :
println(scala.util.parsing.json.JSONObject(m))
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With