json to object gson code example
Example: json to object gson
User user= gson.fromJson(jsonInString, User.class);
// where jsonInString is your json {"userId":"1","userName":"Yasir"}
User user= gson.fromJson(jsonInString, User.class);
// where jsonInString is your json {"userId":"1","userName":"Yasir"}