How do I read and write XML in Cocoa Touch?

前端 未结 2 613
情深已故
情深已故 2020-12-12 03:34

I want to create a file using Objective-C, which stores the data comes from XML. I also have to do basic functions of read and write into that file. How can I do this?

2条回答
  •  隐瞒了意图╮
    2020-12-12 03:58

    You can parse a custom schema using the NSXMLParser class. This is especially useful since the NSXMLDocument class unfortunately does not exist on the iPhone. Thankfully, NSXMLParser is pretty easy to use. I've written an RSS feed parser using NSXMLParser in under half an hour.

提交回复
热议问题