6970717273747576777879
assertNotNull(holder1.instance); doc1.records.add(rec1); StringWriter buff = new StringWriter(); marshaller.marshal(doc1, buff); System.out.println("XML:\n" + buff); Document<Record> doc2 = (Document<Record>) marshaller.unmarshal(new StringReader(buff.toString())); assertNotNull(doc2); assertNotNull(doc2.records);
9293949596979899100101102
System.out.println("ENT: " + ent2); assertNotNull(ent2); assertNotNull(holder2.instance); buff = new StringWriter(); marshaller.marshal(doc2, buff); System.out.println("XML\n" + buff); } @XStreamAlias("document") private static class Document<T>