he wei
2022-11-01 7778893a308cbd28d3c4e5ca7044217532f5d451
'lxw'
1个文件已修改
2 ■■■■■ 已修改文件
src/main/java/com/whyc/dto/XmlFileOpreate.java 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/main/java/com/whyc/dto/XmlFileOpreate.java
@@ -305,8 +305,10 @@
                //System.out.println(mapKey+":"+mapValue);
                //得到第一个mapKey节点
                Node node=document.selectSingleNode("//"+mapKey);
                if(node!=null){
                node.setText(mapValue);
            }
            }
            OutputFormat format = OutputFormat.createPrettyPrint();
            format.setEncoding("UTF-8");//默认的编码就是UTF-8
            XMLWriter writer = new XMLWriter( new FileOutputStream(xmlFilePath), format );