简体   繁体   English

Xcode IAP SKProductsRequest启动方法调用在输出窗口中不显示异常

[英]Xcode IAP SKProductsRequest start method call don't show exception in output window

I am pretty new with xcode and objective c. 我对xcode和目标c相当陌生。 I am trying to implement IAP functionalities. 我正在尝试实现IAP功能。 I implement store handler class and there is some code for review :) 我实现了商店处理程序类,并且有一些代码可供查看:)

在此处输入图片说明

In implementation class a have implemented required handler method 在实现类中,已经实现了必需的处理程序方法

 -(void)productsRequest:(SKProductsRequest *)request didReceiveResponse:(SKProductsResponse *)response{

在此处输入图片说明

I am sure that exception is raised by [productsRequest start]; 我确信[productsRequest start]引发了异常 method because when I remove it nothing happens and there is no exception. 方法,因为当我删除它时,什么也不会发生,也不例外。 When I call [productsRequest start]; 当我打电话给[productsRequest start]时; method exception come up in main method. 方法异常出现在主要方法中。 A exception is rised after 2 or 3 seconds after [productsRequest start]; [productsRequest start]启动 2或3秒后引发异常 method invoked and come up in main method. 方法被调用并出现在main方法中。

在此处输入图片说明

A exception is raised after 2 or 3 seconds after [productsRequest start]; [productsRequest start]之后2或3秒后引发异常 method invoked and come up in main method. 方法被调用并出现在main方法中。 I can not see any exception detail in output console and I cant understand why is happening. 我在输出控制台中看不到任何异常详细信息,也无法理解为什么发生。 If I could see some error message that would be nice and very helpfuly :) I am new in xcode and objective-c and IAP so dont have any idea what o do now :) 如果我能看到一些很好并且非常有帮助的错误消息:)我是xcode和Objective-c和IAP的新手,所以不知道现在该怎么做:)

Please help people! 请帮助人!

I was fighting through a very similar issue. 我正在解决一个非常相似的问题。 I was using an IAP helper to build up the request. 我正在使用IAP助手来建立请求。

My issue turned out to be retaining the instance of my IAP helper. 事实证明,我的问题是保留了IAP帮助程序的实例。 When the data had loaded, it tried to call the delegate, but the original object had been released. 加载数据后,它尝试调用委托,但是原始对象已被释放。

Since the entire IAP mechanism is a black box; 由于整个IAP机制都是黑匣子,因此, the exception occurs outside developer's code because the object created and handed off to the IAP request is no longer there for it to target. 异常发生在开发人员的代码之外,因为创建并移交给IAP请求的对象不再是它的目标。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 不要在xcode中的文档文件夹中显示电影 - don't show movie in document folder in xcode 如何在iOS7中不启动方法 - How to don't start a method in iOS7 不了解XCode项目如何知道如何从Storyboard开始? - Don't understand how the XCode project knows how to start with the Storyboard? 如何在ARC模式下保留自身,例如SKProductsRequest,在start方法中保留自身,然后在响应返回后释放? - how to retain self in ARC mode, such as SKProductsRequest, retain self in start method then release after response come back? NSTimer不要在选择器中调用方法 - NSTimer don't call the method in selector 使用Xcode 5时不显示按钮图像 - Button Images Don't Show When Using Xcode 5 故事板上可见的Xcode图像不会在模拟器中显示 - Xcode images visible in storyboard don't show in simulator 单元测试不要调用viewDidAppear方法 - Unit tests don't call viewDidAppear method 为什么不调用UIViewControllerTransitioningDelegate的方法presentationControllerForPresentedViewController? - Why don't call method presentationControllerForPresentedViewController of UIViewControllerTransitioningDelegate? XCODE 6分配工具不显示自己的类名 - XCODE 6 Allocation Instruments don't show own class name
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM