繁体   English   中英

Flurry 集成错误:找不到符号方法 init()

[英]Flurry Integration Error: Cannot find symbol method init()

在我的应用程序 class 中,在 OnCreate() 中,我添加了以下代码:

new FlurryAgent.Builder()
                .withDataSaleOptOut(false) //CCPA - the default value is false
                .withCaptureUncaughtExceptions(true)
                .withIncludeBackgroundSessionsInMetrics(true)
                .withLogLevel(Log.VERBOSE)
                .withPerformanceMetrics(FlurryPerformance.ALL)
                .build(context, API_KEY);

此外,在 gradle 中,我添加了类似的实现,

implementation 'com.flurry.android:analytics:12.11.0'

现在,当我尝试在方法中添加 FlurryAgent.init(Context, String) 时,我收到错误“找不到符号方法 init(Context, String)。FlurryAgent.setLogEnabled(True )。

这是我第一次使用 Flurry。 谁能指导我?

FlurryAgent.init(Context, String)方法已从 Flurry SDK 中删除。 您应该使用FlurryAgent.Builder()...build(Context, String)来初始化 Flurry。

看起来您已经在这里使用FlurryAgent.Builder.build 您无需再次使用FlurryAgent.init

暂无
暂无

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

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM