I work with the Android Architecture Components and would like to inject a (maybe parameterized) ViewModel into my Activity. But to create the ViewModel I need access to the the activity itself.
Another example is the usage of the of the SupportFragmentManager inside my RecyclerView.Adapter implementation to exchange fragments within the adapter (for example on item click).
Maybe you have an advice for me?