@Test public void testLists() { final String xmlList = "<test xmlns:sli=\"urn:sli\"><l1 sli:member=\"true\">v1</l1><l1 sli:member=\"true\">v2</l1></test>"; EntityBody body = null; try { body = deserialize(xmlList); } catch (XMLStreamException e) { fail(e.getMessage()); } assertNotNull(body); assertTrue("Should be a list", body.get("l1") instanceof List); @SuppressWarnings("unchecked") final List<String> l1Values = (List<String>) body.get("l1"); assertTrue(l1Values.contains("v1")); assertTrue(l1Values.contains("v2")); }
public EntityBody deserialize(final InputStream body) throws XMLStreamException { final XMLInputFactory factory = XMLInputFactory.newInstance(); final XMLStreamReader reader = factory.createXMLStreamReader(body); try { return readDocument(reader); } finally { reader.close(); } }
StAXMsgBodyReader { public EntityBody deserialize(final InputStream body) throws XMLStreamException { final XMLInputFactory factory = XMLInputFactory.newInstance(); final XMLStreamReader reader = factory.createXMLStreamReader(body); try { return readDocument(reader); } finally { reader.close(); } } }
StAXMsgBodyReader { public EntityBody deserialize(final InputStream body) throws XMLStreamException { final XMLInputFactory factory = XMLInputFactory.newInstance(); final XMLStreamReader reader = factory.createXMLStreamReader(body); try { return readDocument(reader); } finally { reader.close(); } }  }
StAXMsgBodyReader { public EntityBody deserialize(final InputStream body) throws XMLStreamException { final XMLInputFactory factory = XMLInputFactory.newInstance(); final XMLStreamReader reader = factory.createXMLStreamReader(body); try { return readDocument(reader); } finally { reader.close(); } }  EntityBody deserialize(final InputStream body); }
StAXMsgBodyReader { public EntityBody deserialize(final InputStream body) throws XMLStreamException { final XMLInputFactory factory = XMLInputFactory.newInstance(); final XMLStreamReader reader = factory.createXMLStreamReader(body); try { return readDocument(reader); } finally { reader.close(); } }  EntityBody deserialize(final InputStream body);  }