Interface ImportExportAwarePlugin<T extends com.atlassian.bamboo.specs.api.builders.plan.configuration.PluginConfiguration<P>,P extends com.atlassian.bamboo.specs.api.model.plan.configuration.PluginConfigurationProperties>

All Superinterfaces:
BambooPluginModule, BuildConfigurationAwarePlugin, InitablePluginModule, RenderableBuildConfiguration
All Known Implementing Classes:
ConcurrentBuildsPlanConfigurationPlugin, HungBuildPlanConfigurationPlugin

public interface ImportExportAwarePlugin<T extends com.atlassian.bamboo.specs.api.builders.plan.configuration.PluginConfiguration<P>,P extends com.atlassian.bamboo.specs.api.model.plan.configuration.PluginConfigurationProperties> extends BuildConfigurationAwarePlugin
Interface for plugin modules that support importing and exporting of their configuration.
  • Method Details

    • getConfigurationKeys

      @NotNull @NotNull Set<String> getConfigurationKeys()
      Return all property keys related to this plugin module which may exist in a plan's BuildConfiguration.

      The returned set may be immutable. If a plugin module doesn't have configuration, then an empty set should be returned.

    • toSpecsEntity

      @NotNull T toSpecsEntity(@NotNull @NotNull org.apache.commons.configuration.HierarchicalConfiguration buildConfiguration)
      Export configuration of this plugin to Bamboo Specs entity.
    • addToBuildConfiguration

      void addToBuildConfiguration(@NotNull P specsProperties, @NotNull @NotNull org.apache.commons.configuration.HierarchicalConfiguration buildConfiguration)
      Validate and add data from specs properties to passed build configuration.
      Parameters:
      specsProperties -
      buildConfiguration -
    • fromYaml

      @Nullable default T fromYaml(Node node) throws com.atlassian.bamboo.specs.api.exceptions.PropertiesValidationException
      Import configuration of this plugin from YAML node to Bamboo Specs entity.
      Parameters:
      node - yaml node
      Returns:
      Bamboo Specs entity for plugin settings.
      Throws:
      com.atlassian.bamboo.specs.api.exceptions.PropertiesValidationException - if configuration is wrong.
    • toYaml

      @Nullable default @Nullable Node toYaml(@NotNull P specsProperties)
      Convert configuration of this plugin from Bamboo Specs to YAML structure.
      Returns:
      YAML Node containing representation of Bamboo Specs entity.