Skip to content

Instantly share code, notes, and snippets.

@PierceZ
Created February 11, 2017 22:00
Show Gist options
  • Save PierceZ/de717c4212a73861ac6f204bfae54536 to your computer and use it in GitHub Desktop.
Save PierceZ/de717c4212a73861ac6f204bfae54536 to your computer and use it in GitHub Desktop.
App class to hold onto a reference of the BusComponent.
public class App extends Application {
private static BusComponent sBusComponent;
@Override
public void onCreate() {
super.onCreate();
sBusComponent = DaggerBusComponent.create();
}
public static BusComponent getBusComponent() {
return sBusComponent;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment