[1]张苗[],惠小强[]. 一种快速的XML文档验证算法[J].计算机技术与发展,2015,25(08):123-127.
 ZHANG Miao[],XI Xiao-qiang[]. A Fast Algorithm of XML Document Verification[J].,2015,25(08):123-127.
点击复制

 一种快速的XML文档验证算法()
分享到:

《计算机技术与发展》[ISSN:1006-6977/CN:61-1281/TN]

卷:
25
期数:
2015年08期
页码:
123-127
栏目:
智能、算法、系统工程
出版日期:
2015-08-10

文章信息/Info

Title:
 A Fast Algorithm of XML Document Verification
文章编号:
1673-629X(2015)08-0123-05
作者:
 张苗[1]惠小强[2]
 1.西安邮电大学 通信工程学院;2.西安邮电大学 物联网与两化融合研究院
Author(s):
 ZHANG Miao[1] XI Xiao-qiang[2]
关键词:
 XML文档复杂类型LIBXML2XML Schema校验
Keywords:
 XML documentscomplex typeLIBXML2XML Schema validation
分类号:
TP311
文献标志码:
A
摘要:
 在用XML( eXtensible Markup Language) Schema校验来判断XML文档合法性的过程中,目前LIBXML2所采用的逐层遍历校验法对3层及以下嵌套效率低下,对多于3层嵌套的校验法失效。针对这一问题,文中提出一种新算法,可有效避免逐层遍历法验证的缺陷。先计算XML文档中某待验证元素出现的次数,然后把该次数分解为XSD( XML Schema Def-inition)文档中所定义的该元素允许出现次数区间内整数的线性组合,计算出所有线性组合中系数和的最小值和最大值。若计算出的系数和范围与XSD文档定义的范围有交集,则验证通过,否则不通过。利用所提算法,对多嵌套和maxOccurs较大的XML文档,验证效率可提高两个数量级。
Abstract:
 When using XML (eXtensible Markup Language) Schema to verify the validation of XML document,the present traversal loop method used by LIBXML2 has low efficiency for no more than 3-loop,and will be invalid for more than 3-loop nested document. To solve the problem,propose a new verification algorithm and it can overcome the defect of traversal loop method. First,the times of ele-ment that will be validated in the XML document is calculated,then this times is divided into the linear combination of the permitted times section that defined in XSD document,next is to calculate the maximum and minimum of summation of the coefficient in all the linear combination. If the range of the coefficient summation can overlap with the range that defined in XSD document,then the validation pas-ses,otherwise fails. Using this method,the validation efficiency can increase two orders for the XML document with multi-loop nested and bigger maxOccurs.

相似文献/References:

[1]张志宏,吴庆波,邵立松,等.基于飞腾平台TOE协议栈的设计与实现[J].计算机技术与发展,2014,24(07):1.
 ZHANG Zhi-hong,WU Qing-bo,SHAO Li-song,et al. Design and Implementation of TCP/IP Offload Engine Protocol Stack Based on FT Platform[J].,2014,24(08):1.
[2]梁文快,李毅. 改进的基因表达算法对航班优化排序问题研究[J].计算机技术与发展,2014,24(07):5.
 LIANG Wen-kuai,LI Yi. Research on Optimization of Flight Scheduling Problem Based on Improved Gene Expression Algorithm[J].,2014,24(08):5.
[3]黄静,王枫,谢志新,等. EAST文档管理系统的设计与实现[J].计算机技术与发展,2014,24(07):13.
 HUANG Jing,WANG Feng,XIE Zhi-xin,et al. Design and Implementation of EAST Document Management System[J].,2014,24(08):13.
[4]侯善江[],张代远[][][]. 基于样条权函数神经网络P2P流量识别方法[J].计算机技术与发展,2014,24(07):21.
 HOU Shan-jiang[],ZHANG Dai-yuan[][][]. P2P Traffic Identification Based on Spline Weight Function Neural Network[J].,2014,24(08):21.
[5]李璨,耿国华,李康,等. 一种基于三维模型的文物碎片线图生成方法[J].计算机技术与发展,2014,24(07):25.
 LI Can,GENG Guo-hua,LI Kang,et al. A Method of Obtaining Cultural Debris’ s Line Chart Based on Three-dimensional Model[J].,2014,24(08):25.
[6]翁鹤,皮德常. 混沌RBF神经网络异常检测算法[J].计算机技术与发展,2014,24(07):29.
 WENG He,PI De-chang. Chaotic RBF Neural Network Anomaly Detection Algorithm[J].,2014,24(08):29.
[7]刘茜[],荆晓远[],李文倩[],等. 基于流形学习的正交稀疏保留投影[J].计算机技术与发展,2014,24(07):34.
 LIU Qian[],JING Xiao-yuan[,LI Wen-qian[],et al. Orthogonal Sparsity Preserving Projections Based on Manifold Learning[J].,2014,24(08):34.
[8]尚福华,李想,巩淼. 基于模糊框架-产生式知识表示及推理研究[J].计算机技术与发展,2014,24(07):38.
 SHANG Fu-hua,LI Xiang,GONG Miao. Research on Knowledge Representation and Inference Based on Fuzzy Framework-production[J].,2014,24(08):38.
[9]叶偲,李良福,肖樟树. 一种去除运动目标重影的图像镶嵌方法研究[J].计算机技术与发展,2014,24(07):43.
 YE Si,LI Liang-fu,XIAO Zhang-shu. Research of an Image Mosaic Method for Removing Ghost of Moving Targets[J].,2014,24(08):43.
[10]余松平[][],蔡志平[],吴建进[],等. GSM-R信令监测选择录音系统设计与实现[J].计算机技术与发展,2014,24(07):47.
 YU Song-ping[][],CAI Zhi-ping[] WU Jian-jin[],GU Feng-zhi[]. Design and Implementation of an Optional Voice Recording System Based on GSM-R Signaling Monitoring[J].,2014,24(08):47.
[11]赵震,张龙昌. XML文档实体识别技术研究[J].计算机技术与发展,2014,24(10):84.
 ZHAO Zhen,ZHANG Long-chang. Research on Entity Identification Technology on XML Documents[J].,2014,24(08):84.
[12]赵震[][],任永昌[]. 大数据时代电子政务中XML文档相似性[J].计算机技术与发展,2017,27(01):186.
 ZHAO Zhen[][],REN Yong-chang[]. Similarity of XML Documents in E-government in Era of Big Data[J].,2017,27(08):186.

更新日期/Last Update: 2015-09-14