WisItDocument extends XmlDocument<WIS> { @Override public WIS toObject() throws JAXBException { return (WIS) WisItUtils.createUnmarshaller().unmarshal(this.getDocument()); } WisItDocument(Document document); static boolean isReadable(Document doc); static WisItDocument newDocument(); static WisItDocument newDocument(WIS wis); @Override WIS toObject();  }
@Test public void testToObject() { try { WisItDocument doc = new WisItDocument(buildExampleDocument()); WIS obj = doc.toObject(); Assert.assertNotNull( "Created object for transfer document.", obj); } catch (Exception ex) { LOGGER.error("Test of WisItDocument.toObject failed!"); LOGGER.error("> " + ex.getLocalizedMessage(), ex); Assert.fail("Test of WisItDocument.toObject failed!"); } }