Since Dagger 2.12 - Importing this project into Eclipse will result in this error:
The method provider(Provider) in the type DoubleCheck is not applicable for the arguments (Factory)
Using plain Maven produces no error.
I found 2 possibilities to fix this error:
- Remove
@Singleton
fromRootView
- Replace
@Module
public abstract class MyModule {
@Binds
@Singleton
public abstract RootViewInterface rootView(RootView rootView);
}
with
@Module
public class MyModule {
@Provides
@Singleton
public static RootViewInterface rootView(RootView rootView) {
return rootView;
};
}