How can JAXB XmlAdapter be used to marshall lists?
问题 Instances of this class are part of a large object graph and are not at the root of the object graph: public class Day { public Day(LocalDate date, List<LocalTime> times) { this.date = date; this.times = times; } public Day() { this(null, null); } public LocalDate getDate() { return date; } public List<LocalTime> getTimes() { return times; } private final LocalDate date; private final List<LocalTime> times; } The object graph is converted to JSON using Jersey and JAXB. I have XmlAdapter s