Class ComponentConstructorImpl<S>

  • All Implemented Interfaces:
    ComponentConstructor<S>

    public class ComponentConstructorImpl<S>
    extends java.lang.Object
    implements ComponentConstructor<S>
    This implementation is used to construct a component instance object, call the constructor and set the activation fields.
    • Field Detail

      • activationFields

        private final java.lang.reflect.Field[] activationFields
      • constructor

        private final java.lang.reflect.Constructor<S> constructor
    • Constructor Detail

    • Method Detail

      • newInstance

        public <T> S newInstance​(ScrComponentContext componentContext,
                                 java.util.Map<ReferenceMetadata,​OpenStatus<S,​?>> parameterMap)
                          throws java.lang.Exception
        Create a new instance
        Specified by:
        newInstance in interface ComponentConstructor<S>
        Parameters:
        componentContext - The component context
        parameterMap - A map of reference parameters for handling references in the constructor
        Returns:
        The instance
        Throws:
        java.lang.Exception - If anything goes wrong, like constructor can't be found etc.
      • getNames

        private java.lang.String getNames​(java.util.List<ReferenceMetadata> refs)