Back to project page NerdRoll.
The source code is released under:
Apache License
If you think the Android project NerdRoll 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 com.bignerdranch.android.nerdroll; /*w w w .j a va2 s . com*/ import android.app.Application; import android.content.Context; import dagger.ObjectGraph; public class MainApplication extends Application { private ObjectGraph mObjectGraph; @Override public void onCreate() { super.onCreate(); mObjectGraph = ObjectGraph.create(new MainApplicationModule(this)); } public static MainApplication get(Context context) { return (MainApplication) context.getApplicationContext(); } public final void inject(Object object) { mObjectGraph.inject(object); } }