可以code,当我的Andr​​oid应用程序卸载被称为? [英] Can code be called when my Android application is uninstalled?

查看:103
本文介绍了可以code,当我的Andr​​oid应用程序卸载被称为?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

有谁知道,如果一个特定的方法是可用的,当我卸载应用程序被重写?这将是很好,从服务器端数据库中删除这些用户,当出现这种情况。

Does anyone know if a specific method is available to be overridden when my application is uninstalled? It would be nice to remove these users from the server side database when this occurs.

推荐答案

不幸的是,目前还没有办法对Android包执行code它被删除时。但是,你可以注册一个<一个href="http://developer.android.com/reference/android/content/BroadcastReceiver.html"><$c$c>BroadcastReceiver为<一个href="http://developer.android.com/reference/android/content/Intent.html#ACTION_PACKAGE_REMOVED"><$c$c>ACTION_PACKAGE_REMOVED 在不同的包的包时,从手机中取出,将被调用。

Unfortunately there is currently no way for an Android package to execute code when it is removed. However, you can register a BroadcastReceiver for ACTION_PACKAGE_REMOVED in a different package that will be called when packages are removed from the phone.

另请参见这个问题

这篇关于可以code,当我的Andr​​oid应用程序卸载被称为?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆