Service 使用

论坛 期权论坛 脚本     
匿名技术用户   2020-12-27 13:21   143   0

启动和停止Service:

Intent startIntent = new Intent(this, MyService.class);
startService(startIntent); // 启动服务
Intent stopIntent = new Intent(this, MyService.class);
stopService(stopIntent); // 停止服务

转载于:https://www.cnblogs.com/plmmlp09/p/4268714.html

分享到 :
0 人收藏
您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

积分:7942463
帖子:1588486
精华:0
期权论坛 期权论坛
发布
内容

下载期权论坛手机APP