Package org.jvnet.hk2.config
Class InjectionManager
java.lang.Object
org.jvnet.hk2.config.InjectionManager
InjectionManager is responsible for injecting resources into a component. Injection targets are identified by the
injection resolver type attribute.
- Author:
- Jerome Dochez
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionprotected classprotected static classprotected classprotected classprotected classprotected class -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected booleanallowInjection(Method method, Class<?>[] paramTypes) jsr-330 rules are very forgiving.protected voiderror_injectionException(InjectionResolver target, Annotation inject, AnnotatedElement injectionPoint, Throwable e) protected voiderror_InjectMethodIsNotVoid(Method method) voidinject(Object component, Class<?> type, InjectionResolver... targets) Initializes the component by performing injection.voidinject(Object component, ExecutorService es, InjectionResolver... targets) Initializes the component by performing injection.voidinject(Object component, InjectionResolver... targets) Initializes the component by performing injection.protected voidsyncDoInject(Object component, Class<?> type, InjectionResolver... targets) Initializes the component by performing injection.
-
Constructor Details
-
InjectionManager
public InjectionManager()
-
-
Method Details
-
inject
Initializes the component by performing injection.- Parameters:
component- component instance to injecttargets- the injection resolvers to resolve all injection pointsonBehalfOf- the inhabitant to do injection on behalf of
-
inject
Initializes the component by performing injection.- Parameters:
component- component instance to injectes- the ExecutorService to use in order to handle the work loadtargets- the injection resolvers to resolve all injection pointsonBehalfOf- the inhabitant to do injection on behalf of
-
inject
Initializes the component by performing injection.- Parameters:
component- component instance to injecttype- component classtargets- the injection resolvers to resolve all injection points
-
syncDoInject
Initializes the component by performing injection.- Parameters:
component- component instance to injecttype- component classtargets- the injection resolvers to resolve all injection pointsonBehalfOf- the inhabitant to do injection on behalf of
-
error_injectionException
protected void error_injectionException(InjectionResolver target, Annotation inject, AnnotatedElement injectionPoint, Throwable e) -
allowInjection
jsr-330 rules are very forgiving. -
error_InjectMethodIsNotVoid
-