摘要
着重介绍用SAX解析XML文件的解析原理,详细分析SAX这一XML文件解析模型的相关类和接口,之后给出了一个商品定单文件,并用SAX解析XML商品定单文件并将其中的内容读取出来,同时给出SAX解析XML文件的关键代码。最后就SAX的缺点进行了分析,得出结论,从而为SAX在其他领域的相关应用提供理论依据。
The analytical principle of parsing XML documents by SAX is introduced. The related classes and interface of the XML document analytical model of SAX is analyzed in detail, after that, an order form commodity information file is given, through parsing the XML commodity information file by SAX and reading its content, an essential code of parsing XML by SAX can be got at the same time. Finally, the defects of SAX is analyzed, and the theoretical basis of SAX applied in other fields is provided.
出处
《现代电子技术》
2010年第12期55-56,65,共3页
Modern Electronics Technique