[Simple-support] Help with @Replace
Brought to you by:
niallg
|
From: Emilio C. da P. <ecd...@gm...> - 2012-01-23 21:44:52
|
I can't get the annotated method to get called when serializing.
Here is the code:
Solution.java:
@Root
public class Solution
@Element
private String mId;
@Element(required=false)
private String name
@ElementList
private List<Dependent> mDependents;
...
// (Constructors, getters/setters)
...
@Replace
public Solution replaceSolution() {
return new Solution(mId, null, mDependents);
}
}
Dependent.java:
@Root
public class Dependent
@Element
private String mId;
@Element(required=false)
private String name
...
}
What I intend is exclude the Solution#name element from the xml.
Any hint? I tried some trunk versions back to 1200, but no success.
Thanks in advance.
Emilio
|