try {
FileWriter fw = new FileWriter(filePath + File.separator+ DateTools.getDateString(new Date(), "yyyyMMddHHmmss") + ".xml");
fw.write(xmlStr);
fw.flush();
fw.close();
} catch (IOException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
转载于:https://blog.51cto.com/yuke198907/1339274