Women in Technology

Hear us Roar



Article:
  Parsing an XML Document with XPath
Subject:   Fixes for JDK1.5.0_04
Date:   2005-08-17 09:17:47
From:   dvohra09
Response to: Fixes for JDK1.5.0_04

For JDK 5.0 Update 2


replace


NodeSet nodes =
(NodeSet) xPath.evaluate(expression,
inputSource, XPathConstants.NODESET);
NodeList nodeList=(NodeList)nodes;


with

com.sun.org.apache.xml.internal.dtm.ref.DTMNodeList nodeList =
(com.sun.org.apache.xml.internal.dtm.ref.DTMNodeList) xPath.evaluate(expression,
inputSource, XPathConstants.NODESET);