As per code given i want to remove few fields from in ResultJSON. In field I am going pass list of ResultBean.
I am setting fields in result field like resultJson.setResult(ResultBeanList)
Note: ResultBean is not a JSON object. It simple Java bean. Hope You understand my issue.
public class ResultJson<T> {
private Integer success;
private T result;
private String message;
private String errorCode;
}
public class ResultBean implements Serializable {
private static final long serialVersionUID = 1L;
private String customerName;
private String customerCode;
private String customerAlias;
private String pOR;
private String pOD;
}
We can skip/remove fields in JSON but question how can we delete fields from inside of JSON fields.