Merge pull request #439 from hotcoffie/wvp-28181-2.0

增强查询录像列表接口兼容性
pull/441/head
648540858 2022-04-20 14:16:10 +08:00 committed by GitHub
commit 7145ce07e6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 8 additions and 8 deletions

View File

@ -20,8 +20,8 @@ import java.util.*;
/** /**
* dom4j * dom4j
* *
* *
*/ */
public class XmlUtil { public class XmlUtil {
/** /**
@ -31,9 +31,9 @@ public class XmlUtil {
/** /**
* XMLDocument * XMLDocument
* *
* @param xml XMl * @param xml XMl
* *
* @return Document * @return Document
*/ */
public static Element parseXml(String xml) { public static Element parseXml(String xml) {
@ -51,7 +51,7 @@ public class XmlUtil {
/** /**
* elementtext * elementtext
* *
* @param em * @param em
* @param tag tag * @param tag tag
* @return * @return
@ -62,12 +62,12 @@ public class XmlUtil {
} }
Element e = em.element(tag); Element e = em.element(tag);
// //
return null == e ? null : e.getText(); return null == e ? null : e.getText().trim();
} }
/** /**
* xml * xml
* *
* @param node node * @param node node
* @param nodeName nodeName * @param nodeName nodeName
* @return List<Map<String, Object>> * @return List<Map<String, Object>>
@ -106,7 +106,7 @@ public class XmlUtil {
/** /**
* xmljson * xmljson
* *
* @param element * @param element
* @param json * @param json
*/ */