android - Fabric 的“Answers Custom Event”在关闭应用程序之前不起作用 - Android
问题描述
我有一个函数,它会在您关闭应用程序或从最近的任务中删除它之前被调用。为了创建自定义事件,我使用 Fabric 的CustomEvent
.
我正在从应用程序处于前台的其他屏幕获取事件,但即使在关闭应用程序之前我也没有收到任何事件。
clearApplicationData()
在应用程序关闭之前被调用。
请参考以下代码:
public void clearApplicationData(Context context, String clearedFrom)
{
Answers.getInstance().logCustom(new CustomEvent("CLEAR_EVENT")
.putCustomAttribute("Data cleared from", clearedFrom));
}
可能是什么问题?
解决方案
推荐阅读
- c# - 图像不显示。是路径问题吗?
- reactjs - 我应该在发布请求后重新加载整个组件吗?
- java - 子jar部署
- python - 为什么 asyncio.StreamReader.read 返回没有阻塞线程?
- android - 从联系人选择器意图中选择电子邮件、姓名和电话号码
- regex - GA 正则表达式仅在 2 个空格之间分隔一个单词
- azure-devops - 获取 Azure DevOps Pipeline 上跳过的任务列表
- python - 使用 pandas 从 python 行明智地编写 xls
- css - 在 Ionic 4 中使用图标切换侧面菜单
- nfc - APDU 命令从 NFC 卡和 MobileApp 读取 Track1/track2 数据