This is all the right stuff, particularly I'm following what Codahale did for Guava's Optional class.
Unfortunately, the type parameters on the method parameters are erased when in a Scala class despite their existence when created via a Java class.
Luckily, @POST methods find a way to give jackson-module-scala all of the type information for body-based parameters when the method consumes JSON. So it should be possible, just need to reproduce what it does.
I'm check pointing this change here so that I can work on cross-compiling several version of scala.
Let me know if anything catches your eye in a bad way.
This is all the right stuff, particularly I'm following what Codahale did for Guava's Optional class.
Unfortunately, the type parameters on the method parameters are erased when in a Scala class despite their existence when created via a Java class.
Luckily, @POST methods find a way to give jackson-module-scala all of the type information for body-based parameters when the method consumes JSON. So it should be possible, just need to reproduce what it does.
I'm check pointing this change here so that I can work on cross-compiling several version of scala.
Let me know if anything catches your eye in a bad way.