org.dom4j.DocumentException: null Nested exception: null
报上面的错误怎么解决?
代码:
public static Object[] iterateWholeXMLtest(String filename) throws DocumentException {
System.out.println("filename="+filename);
List<Map<String, String>> list = new ArrayList<Map<String, String>>();
Map<String, String> hashMap = new HashMap<String, String>();
Document document = DocumentHelper.parseText(filename);
Element root = document.getRootElement();
}
描述:filename是xml格式的字符串不是文件路径