Class DefaultBeanConfigurationRequest

    • Constructor Detail

      • DefaultBeanConfigurationRequest

        public DefaultBeanConfigurationRequest()
    • Method Detail

      • getBean

        public java.lang.Object getBean()
        Description copied from interface: BeanConfigurationRequest
        Gets the bean to configure. Eventually, a valid request must have a bean set.
        Specified by:
        getBean in interface BeanConfigurationRequest
        Returns:
        The bean to configure, or null if none.
      • setConfiguration

        public DefaultBeanConfigurationRequest setConfiguration​(java.lang.Object configuration)
        Description copied from interface: BeanConfigurationRequest
        Sets the configuration to unmarshal into the bean. The configuration should be taken from ConfigurationContainer.getConfiguration() or a similar source. Fully equivalent to setConfiguration(configuration, null).
        Specified by:
        setConfiguration in interface BeanConfigurationRequest
        Parameters:
        configuration - The configuration to unmarshal, may be null.
        Returns:
        This request for chaining, never null.
      • setConfiguration

        public DefaultBeanConfigurationRequest setConfiguration​(java.lang.Object configuration,
                                                                java.lang.String element)
        Description copied from interface: BeanConfigurationRequest
        Sets the configuration to unmarshal into the bean. The configuration should be taken from ConfigurationContainer.getConfiguration() or a similar source. If element is not null, child configuration element with the specified name will be unmarshaled.
        Specified by:
        setConfiguration in interface BeanConfigurationRequest
        Parameters:
        configuration - The configuration to unmarshal, may be null.
        element - Configuration element name to unmarshal or null to unmarshal entire configuration.
        Returns:
        This request for chaining, never null.
      • setConfiguration

        public DefaultBeanConfigurationRequest setConfiguration​(org.apache.maven.model.Model model,
                                                                java.lang.String pluginGroupId,
                                                                java.lang.String pluginArtifactId,
                                                                java.lang.String pluginExecutionId)
        Sets the configuration to the configuration taken from the specified build plugin in the POM. First, the build plugins will be searched for the specified plugin, if that fails, the plugin management section will be searched.
        Parameters:
        model - The POM to extract the plugin configuration from, may be null.
        pluginGroupId - The group id of the plugin whose configuration should be used, must not be null or empty.
        pluginArtifactId - The artifact id of the plugin whose configuration should be used, must not be null or empty.
        pluginExecutionId - The id of a plugin execution whose configuration should be used, may be null or empty to use the general plugin configuration.
        Returns:
        This request for chaining, never null.
      • getClassLoader

        public java.lang.ClassLoader getClassLoader()
        Description copied from interface: BeanConfigurationRequest
        Gets the class loader from which to load any types referenced by the configuration. If unset, the class loader of the bean class will be used.
        Specified by:
        getClassLoader in interface BeanConfigurationRequest
        Returns:
        The class loader to load referenced types from or null if unset.
      • setClassLoader

        public DefaultBeanConfigurationRequest setClassLoader​(java.lang.ClassLoader classLoader)
        Description copied from interface: BeanConfigurationRequest
        Sets the class loader from which to load any types referenced by the configuration. If unset, the class loader of the bean class will be used.
        Specified by:
        setClassLoader in interface BeanConfigurationRequest
        Parameters:
        classLoader - The class loader to load referenced types from, may be null.
        Returns:
        This request for chaining, never null.