NSJSONSerialization

前端之家收集整理的这篇文章主要介绍了NSJSONSerialization前端之家小编觉得挺不错的,现在分享给大家,也给大家做个参考。
我有一些公共json服务的问题
以这种方式格式化服务
jsonFlickrFeed({
        "title": "Uploads from everyone","link": "http://www.flickr.com/photos/","description": "","modifi ... })

NSJSONSerialization似乎无法开展工作

NSURL *jsonUrl = [NSURL URLWithString:@"http://d.yimg.com/autoc.finance.yahoo.com/autoc?query=yahoo&callback=YAHOO.Finance.SymbolSuggest.ssCallback"];
NSError *error = nil;
NSData *jsonData = [NSData dataWithContentsOfURL:jsonUrl options:kNilOptions error:&error];
NSMutableDictionary *jsonResponse = [NSJSONSerialization JSONObjectWithData:jsonData options:NSJSONReadingAllowFragments error:&error];
NSLog(@"%@",jsonResponse);
原文链接:https://www.f2er.com/json/288487.html

猜你在找的Json相关文章