Last active
August 29, 2015 14:16
-
-
Save lukaspili/51c0b0e9286879c02e4e to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class SimpleActivity extends Activity { | |
@Inject | |
Api api; | |
@Inject | |
ApiManager apiManager; | |
@Override | |
protected void onCreate(Bundle savedInstanceState) { | |
super.onCreate(savedInstanceState); | |
DemortarApp.getDemortarApp(this).getComponent().inject(this); | |
api.itWorks(); | |
apiManager.useApi(); | |
// true, same instances | |
boolean test = api == apiManager.getApi(); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment