Cocoa的JSON解析器 [英] JSON parser for Cocoa

查看:133
本文介绍了Cocoa的JSON解析器的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我从iOs开始。我想知道是否有一个内置的JSON解析器,如果没有,什么是将JSON字符串映射为Cocoa对象的最佳替代方法。

I'm starting with iOs. I'd like to know if there is a built-in JSON parser and , if not, what is the best alternative for mapping JSON string into Cocoa objects.

谢谢

推荐答案

如果您仅定位iOS 5,那么内置的NSJSONSerialization类将很好地完成这项工作。如果你需要它在旧版本的iOS中工作,那么像SBJSON的东西对我来说很好。

If you are targeting iOS 5 only, then there is the built-in NSJSONSerialization class that will do the job nicely. If you need it to work in older versions of iOS, then something like SBJSON works well for me

这篇关于Cocoa的JSON解析器的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆