- @Singleton
- @Component(modules = [GreetingModule::class])
- interface ApplicationComponent {
- @Component.Factory
- interface Factory {
- fun build(@BindsInstance context: Context): ApplicationComponent
- }
-
- val greetingHandlerFactory: GreetingHandler.Factory
+ @Component @Singleton
+ abstract class ApplicationComponent(
+ @get:Provides val context: Context,
+ ) : GreetingModule {
+ abstract val greetingHandlerCreator: (String) -> GreetingHandler
+ }
Created
March 8, 2023 13:39
-
-
Save tfcporciuncula/1e9d79e8141024accd6dd2fb1271ad8d to your computer and use it in GitHub Desktop.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment