StartedService与BoundService 以及IntentService的简单使用
StartedService使用步骤:
1.继承Service类实现自己的服务
Service过程如下:
a.onCreate() //只在服务第一次创建时调用
b.onStartCommand(Intent intent, int flags, int startId) //每次启动服务都会调用
c.onDestroy()
2.在AndroidManifest中注册服务
3.启
原创
2015-09-08 18:44:17 ·
853 阅读 ·
0 评论