ursus
10/02/2020, 10:56 PMgildor
10/04/2020, 12:24 AMursus
10/04/2020, 4:41 AM@Module
class MyEmptySetModule {
@Provides @ElementsIntoSet
static Set<Foo> primeEmptyFooSet() {
return Collections.emptySet();
}
}
gildor
10/04/2020, 4:53 AMYou do not have to use @Multibinds for sets or maps that have at least one @IntoSet, @ElementsIntoSet, or @IntoMap binding, but you do have to declare them if they may be empty.
ursus
10/04/2020, 1:16 PMgildor
10/04/2020, 2:00 PM