iPhone SDK:编辑XML文件 [英] iPhone SDK:Editing XML files
本文介绍了iPhone SDK:编辑XML文件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
是否有任何外部库可用来编辑和保存iPhone应用程序的XML文件?
Is there any external library using which one can edit and save XML files for an iPhone application?
推荐答案
A rather good way to handle XML on the iPhone is using the KissXML library hosted at http://code.google.com/p/kissxml
使用DDXMLDocument对象将允许您使用-(NSData *)XMLData
Using a DDXMLDocument object will allow you to get the data with - (NSData *)XMLData
您可以使用 writeToURL:atomically:
或 writeToFile:atomically:
轻松地将NSData写入文件,如
You can write NSData easily to a file using writeToURL:atomically:
or writeToFile:atomically:
as described in the Apple documentation
这篇关于iPhone SDK:编辑XML文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文