我从服务器api获取xml响应。而解析xml .im获取空指针exception.below是xml响应和code.im能够获取单个节点列表但获得异常“kd.in setHighscore ()“
// xml回复
<int xmlns="http://schemas.microsoft.com/2003/10/Serialization/">700</int>
Document doc = getDomElement(responseXML);
NodeList nl = doc.getElementsByTagName("int");
Log.v("node","no of nodes present"+nl.getLength());
HighestScore kd = new HighestScore();
try
{
kd.setHighScore( ((Node) nl.item(0)).getNodeValue());
}
catch(Exception e)
{
Log.e("MYAPP", "exception", e);
}
return kd;