使用jdom解析xml文件和xml格式的字符串
使用jdom解析xml格式的字符串
String resCode = “”;
StringReader read = new StringReader(resCode);
InputSource source = new InputSource(read);
SAXBuilder sb = new SAXBuilder(); Document doc = sb.build(source);
使用jdom解析xml文件
SAXBuilder sb = new SAXBuilder();
Document doc = sb.build(“c:\test.xml”);