StringWriter writer = new StringWriter();
context.createMarshaller().marshal(library, writer);
System.out.println("Badger: ");
String s = writer.toString();
System.out.println(s);
Library lib = (Library) context.createUnmarshaller().unmarshal(new StringReader(s));
Assert.assertEquals(lib.getName(), "BPL");
Assert.assertEquals(lib.getBooks().size(), 2);
}
{
JettisonMappedContext context = new JettisonMappedContext(Library.class);