Hello,
Does anyone have an example of how to implement Jackson's @JsonView to work
during deserialization? I would like to be able to deserialize directly in
the resource method differently depending on the method.
It would be nice to be able to do something close to this:
@POST
@Path("/book/create")
@Produces(MediaType.APPLICATION_JSON)
public Response create(@JsonView(BookViews.create.class) Book book) throws
Exception {
}
@POST
@Path("/book/update")
@Produces(MediaType.APPLICATION_JSON)
public Response create(@JsonView(BookViews.update.class) Book book) throws
Exception {
}
Any thoughts is much appreciated.
Thanks.