From c37f23a5605ed2c6932aa75dffa710cb4f0b5a5f Mon Sep 17 00:00:00 2001 From: zjz1993 <1429595365@qq.com> Date: Thu, 29 Aug 2019 19:04:18 +0800 Subject: [PATCH] update --- src/main/java/com/fanruan/api/xml/XmlKit.java | 40 ++++++++++--------- 1 file changed, 22 insertions(+), 18 deletions(-) diff --git a/src/main/java/com/fanruan/api/xml/XmlKit.java b/src/main/java/com/fanruan/api/xml/XmlKit.java index c416cfa..066747d 100644 --- a/src/main/java/com/fanruan/api/xml/XmlKit.java +++ b/src/main/java/com/fanruan/api/xml/XmlKit.java @@ -6,42 +6,46 @@ import com.fr.stable.xml.XMLReadable; import com.fr.stable.xml.XMLTools; import com.fr.stable.xml.XMLable; import com.fr.stable.xml.XMLableReader; +import com.fr.stable.xml.*; +import com.fr.general.xml.GeneralXMLTools; import java.io.InputStream; -/** - * xml读写相关类 - */ public class XmlKit { /** * 从输入流中读取对象 + * @param xmlReadable xml读取对象 + * @param inputStream xml输入流 + * + */ + /** + * 将java对象写为xml文件 * - * @param read xml读取对象 - * @param in xml输入流 + * @param writer xml写入器 + * @param xml 实际java对象 + * @param tagName xml标签名 */ - public static void readInputStreamXML(XMLReadable read, InputStream in) throws Exception { - XMLTools.readInputStreamXML(read, in); + public static void readInputStreamXML(XMLReadable xmlReadable, InputStream inputStream) throws Exception { + XMLTools.readInputStreamXML(xmlReadable, inputStream); } - - /** - * 将xml读取为具体的java对象 + * 从输入源中读取xml + * @param reader 输入源 + * @return xml文件 * - * @param reader xml读取器 - * @return java对象 */ public static XMLable readXMLable(XMLableReader reader) { return GeneralXMLTools.readXMLable(reader); } - /** - * 将java对象写为xml文件 + * 写XMLable + * @param writer 输出源 + * @param xml xml文件 + * @param tagName 标签名 + * @return 节点名 * - * @param writer xml写入器 - * @param xml 实际java对象 - * @param tagName xml标签名 */ public static void writeXMLable(XMLPrintWriter writer, XMLable xml, String tagName) { GeneralXMLTools.writeXMLable(writer, xml, tagName); } -} \ No newline at end of file +}