Class DataBoundConfigurator<T>

    • Constructor Detail

      • DataBoundConfigurator

        public DataBoundConfigurator​(Class<T> clazz)
    • Method Detail

      • getDataBoundConstructor

        @CheckForNull
        public static Constructor getDataBoundConstructor​(@NonNull
                                                          Class type)
      • getTarget

        public Class getTarget()
        Description copied from interface: Configurator
        Target type this configurator can handle.
      • configure

        @NonNull
        public T configure​(CNode c,
                           ConfigurationContext context)
                    throws ConfiguratorException
        Description copied from interface: Configurator
        Configures/creates a Jenkins object based on a tree.
        Specified by:
        configure in interface Configurator<T>
        Overrides:
        configure in class BaseConfigurator<T>
        Parameters:
        c - Map/List/primitive objects (think YAML) that represents the configuration from which a Jenkins object is configured.
        context - Fully configured Jenkins object used as the starting point for this configuration.
        Returns:
        Fully configured Jenkins object that results from this configuration. if no new objects got created, but some existing objects may have been modified, return updated target object.
        Throws:
        ConfiguratorException - if something went wrong, depends on the concrete implementation
      • getName

        @NonNull
        public String getName()
        Description copied from interface: Configurator
        Get a configurator name. This should return the default name for the configurator, used for exporting yaml see Configurator.getNames() for all possible names which will be considered when configuring.
        Returns:
        short name for this component when used in a configuration.yaml file
      • getNames

        @NonNull
        public List<String> getNames()
        Description copied from interface: Configurator
        Get all possible configurator names
        Returns:
        a list of all possible short names for this component when used in a configuration.yaml file
      • getImplementedAPI

        @NonNull
        public Class getImplementedAPI()
        Returns:
        The API implemented by target type, i.e. implemented ExtensionPoint for components to implement some jenkins APIs, or raw type for others.
      • describe

        @CheckForNull
        public CNode describe​(T instance,
                              ConfigurationContext context)
                       throws Exception
        Description copied from interface: Configurator
        Describe a component as a Configuration Nodes CNode to be exported as yaml. Only export attributes which are not set to default value.
        Throws:
        Exception
      • getDisplayName

        public String getDisplayName()
        Returns:
        Human friendly display name for this component, used in generated documentation.