I have this POJO:
public class SetPoint {
private String tagName;
//more fields
//getters and setters
}
I'm getting SetPoints from a REST API, do something with them and then send them again. Problem is that I want deserialize a SetPoint from a JSON like:
{
"tagnameOpc" : "6GH783",
//more fields
}
But when I send them, I want serialize a SetPoint as:
{
"tagName" : "6GH783"
//more fields
}
I mean, I want the property tagName
to be named different in each case.
Is this possible?