【发布时间】:2015-08-24 01:47:44
【问题描述】:
我刚刚将 Flurry 添加到我的项目中,有些事情不是很清楚。例如,我想跟踪 ViewController1 和 ViewController2,我该如何完成?我应该将以下代码添加到我的 AppDelegate 的 didFinishLaunchingWithOptions: 中,它准备好了吗?或者我需要在每个视图控制器的viewWillAppear: 中设置logAllPageViewsForTarget:?
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {
[Flurry startSession:@"sampleID"];
UIViewController *viewController1 =
[[UIStoryboard storyboardWithName:@"MainStoryboard" bundle:nil]instantiateViewControllerWithIdentifier:@"storyboardIDofViewController1"];
UIViewController *viewController2 =
[[UIStoryboard storyboardWithName:@"MainStoryboard" bundle:nil]instantiateViewControllerWithIdentifier:@"storyboardIDofViewController2"];
[Flurry logAllPageViewsForTarget:viewController1];
[Flurry logAllPageViewsForTarget:viewController2];
return yes;
}
我什么时候需要致电stopLogPageViewsForTarget:?当用户关闭应用程序时总是需要它,或者它在实践中的功能是什么?
实际上我在我的AppDelegate 中使用logAllPageViewsForTarget:,但是在我的管理面板中,当我打开Page Views 部分时,我会收到以下消息:
您当前没有跟踪页面浏览数据。页面查看跟踪是 Flurry SDK 的可选部分,允许您报告 您的用户出于以下目的而生成的页面浏览量 跟踪广告。由于页面视图的定义不同 每个应用程序,Flurry SDK 无法为您跟踪这些 自动地。相反,您需要添加适当的集成 跟踪与您的应用程序相关的页面浏览量的点。
我错过了什么重要的事情吗?
【问题讨论】:
标签: ios objective-c flurry flurry-analytics