There is a generic fragment
public class MyFragment<TYPE> extends Fragment {
@Inject
SomeClass class;
public MyFragment(){}
}
}
I am not able to add this Fragment to the Fragment Binding Module as Dagger complains it is of raw type.
How do I mention the TYPE class in the binding module?
My binding module looks like this for now:
@Module
public abstract class BindingModule {
@ContributesAndroidInjector(modules = MyFragmentModule.class)
abstract MyFragment bindMyFragment();
}
Error
error: [dagger.android.AndroidInjector.inject(T)] MyFragment has type parameters, cannot members inject the raw type.