Class ConcurrentBuildsPlanConfigurationPlugin

java.lang.Object
com.atlassian.bamboo.v2.build.BaseBuildConfigurationAwarePlugin
com.atlassian.bamboo.build.configuration.ConcurrentBuildsPlanConfigurationPlugin
All Implemented Interfaces:
MiscellaneousPlanConfigurationPlugin, PlanConfigurationUiPlugin, InitablePluginModule, BambooPluginModule, BuildConfigurationAwarePlugin, ImportExportAwarePlugin<com.atlassian.bamboo.specs.api.builders.plan.configuration.ConcurrentBuilds,com.atlassian.bamboo.specs.api.model.plan.configuration.ConcurrentBuildsProperties>, RenderableBuildConfiguration

public class ConcurrentBuildsPlanConfigurationPlugin extends BaseBuildConfigurationAwarePlugin implements MiscellaneousPlanConfigurationPlugin, ImportExportAwarePlugin<com.atlassian.bamboo.specs.api.builders.plan.configuration.ConcurrentBuilds,com.atlassian.bamboo.specs.api.model.plan.configuration.ConcurrentBuildsProperties>
  • Field Details

  • Constructor Details

    • ConcurrentBuildsPlanConfigurationPlugin

      public ConcurrentBuildsPlanConfigurationPlugin()
  • Method Details

    • populateContextForView

      protected void populateContextForView(@NotNull @NotNull Map<String,Object> context, @NotNull @NotNull Plan plan)
      Overrides:
      populateContextForView in class BaseBuildConfigurationAwarePlugin
    • validate

      @NotNull public @NotNull ErrorCollection validate(@NotNull @NotNull BuildConfiguration buildConfiguration)
      Description copied from interface: BuildConfigurationAwarePlugin
      Validates the properties in the BuildConfiguration object. The name of the properties match those passed in through the form fragments in RenderableBuildConfiguration.getEditHtml(com.atlassian.bamboo.ww2.actions.build.admin.create.BuildConfiguration, com.atlassian.bamboo.plan.Plan) template.
      Specified by:
      validate in interface BuildConfigurationAwarePlugin
      Overrides:
      validate in class BaseBuildConfigurationAwarePlugin
      Parameters:
      buildConfiguration - -
      Returns:
      ErrorCollection keyed by the field name.
    • isApplicableTo

      public boolean isApplicableTo(@NotNull @NotNull ImmutablePlan plan)
      Description copied from interface: PlanConfigurationUiPlugin
      Checks if the plugin is applicable to a plan. Typical implementation is to check plan's type (chain, build, job).
      Specified by:
      isApplicableTo in interface PlanConfigurationUiPlugin
      Parameters:
      plan - Plan to be verified
      Returns:
      true if particular configuration is applicable to input plan
    • toSpecsEntity

      @NotNull public @NotNull com.atlassian.bamboo.specs.api.builders.plan.configuration.ConcurrentBuilds toSpecsEntity(@NotNull @NotNull org.apache.commons.configuration.HierarchicalConfiguration buildConfiguration)
      Description copied from interface: ImportExportAwarePlugin
      Export configuration of this plugin to Bamboo Specs entity.
      Specified by:
      toSpecsEntity in interface ImportExportAwarePlugin<com.atlassian.bamboo.specs.api.builders.plan.configuration.ConcurrentBuilds,com.atlassian.bamboo.specs.api.model.plan.configuration.ConcurrentBuildsProperties>
    • addToBuildConfiguration

      public void addToBuildConfiguration(@NotNull @NotNull com.atlassian.bamboo.specs.api.model.plan.configuration.ConcurrentBuildsProperties specsProperties, @NotNull @NotNull org.apache.commons.configuration.HierarchicalConfiguration buildConfiguration)
      Description copied from interface: ImportExportAwarePlugin
      Validate and add data from specs properties to passed build configuration.
      Specified by:
      addToBuildConfiguration in interface ImportExportAwarePlugin<com.atlassian.bamboo.specs.api.builders.plan.configuration.ConcurrentBuilds,com.atlassian.bamboo.specs.api.model.plan.configuration.ConcurrentBuildsProperties>
    • toYaml

      @Nullable public @Nullable Node toYaml(@NotNull @NotNull com.atlassian.bamboo.specs.api.model.plan.configuration.ConcurrentBuildsProperties specsProperties)
      Description copied from interface: ImportExportAwarePlugin
      Convert configuration of this plugin from Bamboo Specs to YAML structure.
      Specified by:
      toYaml in interface ImportExportAwarePlugin<com.atlassian.bamboo.specs.api.builders.plan.configuration.ConcurrentBuilds,com.atlassian.bamboo.specs.api.model.plan.configuration.ConcurrentBuildsProperties>
      Returns:
      YAML Node containing representation of Bamboo Specs entity.
    • fromYaml

      @Nullable public @Nullable com.atlassian.bamboo.specs.api.builders.plan.configuration.ConcurrentBuilds fromYaml(@NotNull @NotNull Node node) throws com.atlassian.bamboo.specs.api.exceptions.PropertiesValidationException
      Description copied from interface: ImportExportAwarePlugin
      Import configuration of this plugin from YAML node to Bamboo Specs entity.
      Specified by:
      fromYaml in interface ImportExportAwarePlugin<com.atlassian.bamboo.specs.api.builders.plan.configuration.ConcurrentBuilds,com.atlassian.bamboo.specs.api.model.plan.configuration.ConcurrentBuildsProperties>
      Parameters:
      node - yaml node
      Returns:
      Bamboo Specs entity for plugin settings.
      Throws:
      com.atlassian.bamboo.specs.api.exceptions.PropertiesValidationException - if configuration is wrong.
    • getConfigurationKeys

      @NotNull public @NotNull Set<String> getConfigurationKeys()
      Description copied from interface: ImportExportAwarePlugin
      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.

      Specified by:
      getConfigurationKeys in interface ImportExportAwarePlugin<com.atlassian.bamboo.specs.api.builders.plan.configuration.ConcurrentBuilds,com.atlassian.bamboo.specs.api.model.plan.configuration.ConcurrentBuildsProperties>
    • setAdministrationConfigurationAccessor

      public void setAdministrationConfigurationAccessor(AdministrationConfigurationAccessor administrationConfigurationAccessor)
    • setTextProvider

      public void setTextProvider(com.opensymphony.xwork2.TextProvider textProvider)