java.lang.Object
io.avaje.inject.spi.SuppliedBean
Holds beans supplied to the dependency injection.
These can be externally supplied dependencies or test doubles for testing purposes.
-
Method Summary
Modifier and TypeMethodDescriptionfinal Class<?>[]Return the interfaces to additionally register along with the type.final Stringname()Return the qualifier name of the supplied bean.static SuppliedBeanCreate with a class type and bean instance.static <B> SuppliedBeanCreate for a class type with name.static <B> SuppliedBeanCreate for a class type with a consumer that runs once when the bean is obtained.static SuppliedBeanCreate a supplied bean for a generic type.final intpriority()Return the associated priority.static SuppliedBeanCreate a supplied bean with SECONDARY priority as a default fallback dependency that is only used when no other matching one is provided.source()Return the bean instance or provider to use for injection.final Typetype()Return the dependency injection target type.
-
Method Details
-
of
Create with a class type and bean instance. -
of
Create for a class type with a consumer that runs once when the bean is obtained. -
of
Create for a class type with name. -
ofType
Create a supplied bean for a generic type. -
secondary
Create a supplied bean with SECONDARY priority as a default fallback dependency that is only used when no other matching one is provided. -
source
Return the bean instance or provider to use for injection. -
priority
Return the associated priority. -
type
Return the dependency injection target type. -
name
Return the qualifier name of the supplied bean. -
interfaces
Return the interfaces to additionally register along with the type.
-