MetadataXpathNodeListQuery extends MetadataXpathQueryImpl implements XpathObjectQuery { @Override public NodeList resolveXpath(Document doc, XPath xpath, String expr) throws CoreException { return XpathQueryHelper.resolveNodeList(doc, xpath, expr, allowEmptyResults()); } MetadataXpathNodeListQuery();  MetadataXpathNodeListQuery(String metadataKey, String xpathMetadataKey); @Override NodeList resolveXpath(Document doc, XPath xpath, String expr);  }
@Test public void testResolveXpath() throws Exception { MetadataXpathNodeListQuery query = init(create()); Document doc = XmlHelper.createDocument(XML); AdaptrisMessage msg = AdaptrisMessageFactory.getDefaultInstance().newMessage(XML); msg.addMetadata("xpathMetadataKey", " NodeList result = query.resolveXpath(doc, new XPath(), query.createXpathQuery(msg)); assertNotNull(result); }