Error while serializing generic case class.

4 views
Skip to first unread message

MADHUSUDAN D

unread,
May 2, 2016, 7:17:38 AM5/2/16
to spray.io User List
Hi,
I am new to scala and spray-json.
I am getting error : Can not find jsonWriter of jsonFormat type for class abc[A]. This is my example

case class abc[+T](msg: T)

implicit def abcFomat[A: JsonFormat] = jsonFormat1(abc.apply[A])

def test[A] (a:abc[A])={
    println(a.toJson) 
  }



Reply all
Reply to author
Forward
0 new messages