io.circe encoder for java.lang.Object in scala

Viewed 100

How to encode java.lang.Object using io.circe

Basically I am trying encode a Map

Map(
   "key" -> Option[Json].map(_.asObject).getOrElse(Map.empty) // `object[a -> "x",b -> "y",c -> "z"]`
   ) 

For e.g. I want to convert object[a -> "x",b -> "y",c -> "z"] to {"a":"x", "b":"y","c": "z"}

0 Answers
Related