【发布时间】:2017-03-31 00:42:14
【问题描述】:
我在这里执行这段代码
self.cloudSightQuery = [[CloudSightQuery alloc] initWithImage:imageData
atLocation:CGPointZero
withDelegate:self
atPlacemark:nil
withDeviceId:@""];
self.cloudSightQuery.queryDelegate = self;
[self.cloudSightQuery start];
但有时它会因以下原因而崩溃
由于未捕获的异常“NSInvalidArgumentException”而终止应用程序,原因:'-[ImageViewController cloudSightQueryDidFail:withError:]:无法识别的选择器发送到 实例 0x100514c40'
第一次抛出调用栈:
我如何能够捕获此错误并向用户显示响应而不是应用崩溃?
【问题讨论】:
标签: ios objective-c error-handling cloudsight