许多微博上都这样请求数据
1 NSURL *url = [NSURL URLWithString:@"http://api.twitter.com/1/statuses/public_timeline.json"];
2 NSURLRequest *request = [NSURLRequest requestWithURL:url];
3 AFJSONRequestOperation *operation = [AFJSONRequestOperation JSONRequestOperationWithRequest:request success:^(NSURLRequest *request, NSHTTPURLResponse *response, id JSON)
{
4 NSLog(@"Public Timeline: %@", JSON);
} failure:nil];
5 [operation start];
为什么AFJSONRequestOperation
不能用
iOS开发小白一枚, 每太明白题主意思.
练习的时候还真没使用到
AFJSONRequestOperation
, 一直都是用下面的作者的Demo来请求数据的