I want to convert empty string values from attribute and replace it with null
in my API response model object.
Lets say the API response is Transaction
which contains 2 instance variable of type TransDetails
and UserDetails
. These two model classes contains around 100 string attributes.
Now some of the attributes of TransDetails
and UserDetails
are showing empty string in API response.
How can I change it to null in jackson 2?
I tried this solutions, but its not working in class level.