利用扩展方法改进LINQ to XML数据读取  被引量:1

Improvement of Data Reading in LINQ to XML Using Extension Methods

在线阅读下载全文

作  者:董宁[1] 

机构地区:[1]武汉软件工程职业学院,武汉430205

出  处:《电脑编程技巧与维护》2012年第18期68-69,共2页Computer Programming Skills & Maintenance

摘  要:在读取XML文件中的数据时经常会碰到数据类型不正确或元素属性不完整的情况。这会导致一系列的问题,如果正在利用序列化数据创建对象,碰到XML文件不完整的话,整个对象将无法创建。讨论了利用扩展方法侦测XML文件中缺失的元素,或属性避免因为部分数据丢失而整个对象都无法创建的情况。Incorrect data type or incomplete element attribute is often encountered when reading data in XML files. It will lead to a series of problems. When creating objects with serialized data, if XML file is incomplete, the entire object cannot be created. It is issued how to detect the missing element or attribute by using extension methods, in order to avoid the situation that entire object cannot be created because of missing part of data.

关 键 词:XML LINQ to XML 扩展方法 

分 类 号:TP311.1[自动化与计算机技术—计算机软件与理论]

 

参考文献:

正在载入数据...

 

二级参考文献:

正在载入数据...

 

耦合文献:

正在载入数据...

 

引证文献:

正在载入数据...

 

二级引证文献:

正在载入数据...

 

同被引文献:

正在载入数据...

 

相关期刊文献:

正在载入数据...

相关的主题
相关的作者对象
相关的机构对象