I'm using RestEasy and hibernate to return response in Jackson. I have a bean Player having fields: name, id, age, position.
Now, I'm implementing two GET
rest methods for returing json.
getPlayer()
, which is returning a player: name, id, age, position.getPlayers()
, which is returning a list of players, but with this list of players, i do not want to return position.
I mean, how can I add a field for one response and ignore it for another response.
Please suggest.
Thanks