XPath metares = rootElement.createXPath("//ns:resources");
metares.setNamespaceURIs(nsuris);
Element elResources = (Element) metares.selectSingleNode(rootElement);
if (elResources == null) throw new AssertException("could not find element resources");
List resourcesList = elResources.elements("resource");
resources = new HashMap(resourcesList.size());
for (Iterator iter = resourcesList.iterator(); iter.hasNext();) {
Element elRes = (Element) iter.next();
String identVal = elRes.attributeValue("identifier");
String hrefVal = elRes.attributeValue("href");