Closed GoogleCodeExporter closed 8 years ago
Hm, I have to think about the best way to handle this without adding additional
complexity (like introducing some way to indicate which field is supposed to be
used for Java->JSON when the same annotation exists multiple times) - thanks
for the bug report.
Maybe the simplest is:
If JsonMapper finds multiple annotations for the same field, it checks the
value of each field. If there is only one non-null field, JsonMapper will
marshal that. If there are multiple non-null fields, JsonMapper will pick a
field (which one is undefined) to marshal. What do you think?
Original comment by m...@xmog.com
on 3 May 2012 at 1:50
Fixed in
https://github.com/revetkn/restfb/commit/0de05fff2f57f9508f5f10bb686d19d3cc2c582
2.
The band-aid was that the mapper will selected a field by luck-of-the-draw. I
would like to improve this later but have to make sure it's doable without
adding too much complexity to the public API.
Original comment by m...@xmog.com
on 1 Sep 2012 at 4:42
Original issue reported on code.google.com by
peterm...@gmail.com
on 29 Apr 2012 at 7:02