Back to project page DistributedMemory.
The source code is released under:
Apache License
If you think the Android project DistributedMemory listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.
package org.faudroids.distributedmemory.common; /*from w w w . j av a2 s. c o m*/ import android.app.Service; import java.util.List; import dagger.ObjectGraph; public abstract class BaseService extends Service { private ObjectGraph objectGraph; @Override public void onCreate() { super.onCreate(); this.objectGraph = ((Injector) getApplication()).createScopedGraph(getModules().toArray()); this.objectGraph.inject(this); } @Override public void onDestroy() { objectGraph = null; super.onDestroy(); } protected abstract List<Object> getModules(); }