我正在尝试实现一个简单的 TTURLRequest 在我的应用程序中。我对Three20框架相当陌生。我主要想要 TTURLRequest 和 TTImageView
TTURLRequest
TTImageView
我的委托中有以下代码:
- (void)requestDidFinishLoad:(TTURLRequest*)request { TTURLDataResponse *response = request.response; // Stuff to process response.data }
response
调试您的代码-在发送请求之前,您实际上必须创建响应对象并将其添加到请求中:
NSString *url = @"http://twitter.com/statuses/user_timeline/samsoffes.json?count=1"; TTURLRequest *theRequest = [[TTURLRequest alloc] initWithURL:url delegate:self]; theRequest.response = [[[TTURLDataResponse alloc] init] autorelease]; [theRequest send];
有人会认为请求将负责创建响应,但Three20的东西没有。
http://revetkn.com/?p=72