Hacked By Imam with love
You are a lifesaver. I’ve spent all morning trying to work out a very similar scenario – I have a type parameter from the Yammer API.
Haven’t tried it out yet but what you have looks spot on for my needs. Thank you again for taking the time to document this so clearly 🙂
Well, I’m nearly there. I get the following exception:
[MappingException: No usable value for type Did not find value which can be converted into java.lang.String]
It seems to be caused by the “override val typeHintFieldName” line. I don’t suppose you have any ideas?
Ha! Worked that last one out – I had a case class with an attribute called `type`.
Glad you’re squared away, Colin. You’re welcome and happy coding.
Similar to the earlier poster, I spent my entire morning trying to make this work. In my case , I was sending JSON for objects with multi level inheritance to a Scala server. Adding type hints to the .NET serializer and following above steps for worked for me.
Mail (will not be published) (required)
XHTML: You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>
Copyright © 2011 Scalafied · Powered by WordPress · iTech Theme by Zack