Am developing a cocoa app开发者_如何学Pythonlication, where I have to invoke java web scripts and fetch the response of the web script object and convert it into Objective C readable objects. I would then need to manipulate the fetched data for import, print, etc.
How to I interact with the web script and convert into cocoa readable objects?
Any pointers on the same, will be appreciated.
Thanks, Nana
Convert the JSON string into an
NSDictionary
using tools like yajl, JSONKit or iOS5 JSONUse https://github.com/elado/jastor to convert this NSDictionary to a real Objective-C class with typed properties, nested properties, arrays etc.
In iOS 5 native JSON parsing is supported (documentation). In addition you can use a number of third party libraries to download and parse JSON (see JSONKit and HTTPRiot or RestKit)
A full reference of awesome libraries can be found here.
精彩评论