You can also spawn your own shorter lived scopes to manage transient sessions, like the state of an object being built by a set of wizard screens.
These nested scopes can shadow the services provided by higher level scopes.
How this can be achieved? E.g. I have activity scope that provides dagger component and I want to spawn nested subscope(to provide subcomponent) that should shadow activity's dagger component. I'm using flow and I need to spawn subscope for several screens so the views of this screens will get subcomponent with Context.getSystemService instead of activity's component.
If I use buildChild() on acivity's scope then subscope will be just child of this scope, but it not shadows parent scope. Thanks.
How this can be achieved? E.g. I have activity scope that provides dagger component and I want to spawn nested subscope(to provide subcomponent) that should shadow activity's dagger component. I'm using flow and I need to spawn subscope for several screens so the views of this screens will get subcomponent with Context.getSystemService instead of activity's component.
If I use buildChild() on acivity's scope then subscope will be just child of this scope, but it not shadows parent scope. Thanks.