在BroadcastReceiver中使用RoboSpice

时间:2014-04-03 09:57:58

标签: android android-broadcast robospice

我想知道是否可以在BroadcastReceiver中使用RoboSpice,如果是,我应该如何处理生命周期?

现在我只是在spiceManager.start(context)方法中调用onReceive(Context, Intent),但服务永远不会停止。

加埃唐

1 个答案:

答案 0 :(得分:1)

我不知道更多,我会说最好的选择是在onReceive处理结束时调用SpiceManager的shouldStop方法,或者在触发请求监听器时调用。