Class ComponentConstructorImpl<S>
java.lang.Object
org.apache.felix.scr.impl.inject.internal.ComponentConstructorImpl<S>
- All Implemented Interfaces:
ComponentConstructor<S>
This implementation is used to construct a component instance object,
call the constructor and set the activation fields.
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final Field[]private final ValueUtils.ValueType[]private final Constructor<S> private final ValueUtils.ValueType[]private final ReferenceMetadata[] -
Constructor Summary
ConstructorsConstructorDescriptionComponentConstructorImpl(ComponentMetadata componentMetadata, Class<S> componentClass, ComponentLogger logger) -
Method Summary
Modifier and TypeMethodDescriptionprivate StringgetNames(List<ReferenceMetadata> refs) <T> SnewInstance(ScrComponentContext componentContext, Map<ReferenceMetadata, OpenStatus<S, ?>> parameterMap) Create a new instance
-
Field Details
-
activationFields
-
activationFieldTypes
-
constructor
-
constructorArgTypes
-
constructorRefs
-
-
Constructor Details
-
ComponentConstructorImpl
public ComponentConstructorImpl(ComponentMetadata componentMetadata, Class<S> componentClass, ComponentLogger logger)
-
-
Method Details
-
newInstance
public <T> S newInstance(ScrComponentContext componentContext, Map<ReferenceMetadata, OpenStatus<S, ?>> parameterMap) throws ExceptionCreate a new instance- Specified by:
newInstancein interfaceComponentConstructor<S>- Parameters:
componentContext- The component contextparameterMap- A map of reference parameters for handling references in the constructor- Returns:
- The instance
- Throws:
Exception- If anything goes wrong, like constructor can't be found etc.
-
getNames
-