- Type Parameters:
T- the type that the provider produces
- All Superinterfaces:
Provider<T>
- All Known Subinterfaces:
ServiceProvider<T>,ServiceProviderBindable<T>
@Deprecated(forRemoval=true,
since="4.0.8")
public interface InjectionPointProvider<T>
extends Provider<T>
Deprecated, for removal: This API element is subject to removal in a future version.
Helidon inject is deprecated and will be replaced in a future version
Provides ability to contextualize the injected service by the target receiver of the injection point dynamically
at runtime. This API will provide service instances of type
T. These services may be singleton, or created based upon
scoping cardinality that is defined by the provider implementation of the given type. This is why the javadoc reads "get (or
create)".
The ordering of services, and the preferred service itself, is determined by the same as documented for
Services.
-
Method Summary
Modifier and TypeMethodDescriptionfirst(ContextualServiceQuery query) Deprecated, for removal: This API element is subject to removal in a future version.Get (or create) an instance of this service type for the given injection point context.default Tget()Deprecated, for removal: This API element is subject to removal in a future version.Get (or create) an instance of this service type using default/empty criteria and context.list(ContextualServiceQuery query) Deprecated, for removal: This API element is subject to removal in a future version.Get (or create) a list of instances matching the criteria for the given injection point context.
-
Method Details
-
get
Deprecated, for removal: This API element is subject to removal in a future version.Get (or create) an instance of this service type using default/empty criteria and context.- Specified by:
getin interfaceProvider<T>- Returns:
- the best service provider matching the criteria
- Throws:
InjectionException- if resolution fails to resolve a match
-
first
Deprecated, for removal: This API element is subject to removal in a future version.Get (or create) an instance of this service type for the given injection point context. This is logically the same as using the first element of the result from callinglist(ContextualServiceQuery).- Parameters:
query- the service query- Returns:
- the best service provider matching the criteria
- Throws:
InjectionException- if expected=true and resolution fails to resolve a match
-
list
Deprecated, for removal: This API element is subject to removal in a future version.Get (or create) a list of instances matching the criteria for the given injection point context.- Parameters:
query- the service query- Returns:
- the resolved services matching criteria for the injection point in order of weight, or null if the context is not supported
-