Hello !

I have a requirement where I need to select the concrete class based on 
presence of a key field in my json

I have a  base abstract class Activity.java which is extended by 
CommandActivity.java and ViewActivity.java 

Ex -
=====
Json 1

{
"command" : "abc"
"parameters" : ["ls"]
"user" : "iamuser1"
"origin" : "asia"
} 

Json2 

{
"view" : "C001"
"resource":"XYZ"
"user" : "iamuser2"
"origin" : "US"
} 

Based on presence of key command or view, jackson needs to select the right 
concrete class for deserizliation.
 
Wondering if this feature is available already in the framework? If someone 
had similar problem solved earlier, would be awesome if you can share the 
code snippet

Cheers
Reji

-- 
You received this message because you are subscribed to the Google Groups 
"jackson-user" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jackson-user/10a1f412-d873-450b-bf48-9bf7abb20a81n%40googlegroups.com.

Reply via email to