Class BulkPlanAction

java.lang.Object
com.opensymphony.xwork2.ActionSupport
com.atlassian.bamboo.ww2.BambooActionSupport
com.atlassian.bamboo.ww2.actions.admin.bulk.BulkPlanAction
All Implemented Interfaces:
JsonStreamingAction, ErrorCollection, BambooSessionAware, BypassValidationAware, NavigationAware, DomainObjectSecurityAware, GlobalAdminSecurityAware, GlobalReadSecurityAware, ReturnUrlAware, com.atlassian.core.i18n.I18nTextProvider, com.atlassian.struts.TextProvider, com.atlassian.struts.ValidationAware, com.opensymphony.xwork.ValidationAware, com.opensymphony.xwork2.Action, com.opensymphony.xwork2.interceptor.ValidationAware, com.opensymphony.xwork2.LocaleProvider, com.opensymphony.xwork2.TextProvider, com.opensymphony.xwork2.Validateable, Serializable

public class BulkPlanAction extends BambooActionSupport implements GlobalAdminSecurityAware, BypassValidationAware
This class provides a UI action to edit one or more build.
See Also:
  • Constructor Details

    • BulkPlanAction

      public BulkPlanAction()
  • Method Details

    • isValidationBypassed

      public boolean isValidationBypassed()
      Specified by:
      isValidationBypassed in interface BypassValidationAware
    • validate

      public void validate()
      Specified by:
      validate in interface com.opensymphony.xwork2.Validateable
      Overrides:
      validate in class com.opensymphony.xwork2.ActionSupport
    • view

      public String view() throws Exception
      Throws:
      Exception
    • confirm

      public String confirm() throws Exception
      Throws:
      Exception
    • execute

      public String execute() throws Exception
      Update the selected builds
      Specified by:
      execute in interface com.opensymphony.xwork2.Action
      Overrides:
      execute in class com.opensymphony.xwork2.ActionSupport
      Returns:
      The webwork success status
      Throws:
      Exception - A generic failure
    • isApplicable

      public boolean isApplicable(BulkAction bulkAction, Project project)
    • isApplicableForRepositories

      public boolean isApplicableForRepositories(BulkAction bulkAction)
    • isPlanSelected

      public boolean isPlanSelected(String planKey)
    • isRepositorySelected

      public boolean isRepositorySelected(long repositoryId)
    • setSelectedBuilds

      public void setSelectedBuilds(String[] selectedBuilds)
      The checkboxes all have the same name, but with different value. Webwork passes all values as a String array list. The values represent the build keys.
      Parameters:
      selectedBuilds - The key of the builds that have been selected for bulk action.
    • getSelectedBuilds

      public String[] getSelectedBuilds()
    • getSelectedRepositories

      public String[] getSelectedRepositories()
    • setSelectedRepositories

      public void setSelectedRepositories(String[] selectedRepositories)
    • getBulkAction

      @Nullable public @Nullable BulkAction getBulkAction()
    • getSelectedPlans

      @Nullable public @Nullable List<ImmutablePlan> getSelectedPlans()
    • getSelectedRepositoryDefinitions

      @Nullable public @Nullable List<RepositoryDefinition> getSelectedRepositoryDefinitions(Plan plan)
    • getParams

      public Map<String,String[]> getParams()
    • getSortedProjects

      public List<Project> getSortedProjects()
    • getSortedPlans

      public List<? extends ImmutablePlan> getSortedPlans(Project project)
    • getSortedTopLevelPlans

      public List<ImmutableTopLevelPlan> getSortedTopLevelPlans(Project project)
    • getSelectedBulkActionKey

      public String getSelectedBulkActionKey()
    • setSelectedBulkActionKey

      public void setSelectedBulkActionKey(String selectedBulkActionKey)
    • getAvailableBulkActions

      public List<BulkAction> getAvailableBulkActions()
    • getResults

      public org.apache.commons.collections4.map.ListOrderedMap getResults()
    • setBackButton

      public void setBackButton(String backButton)
    • getSecuredDomainObject

      public Object getSecuredDomainObject()
      Specified by:
      getSecuredDomainObject in interface DomainObjectSecurityAware
      Overrides:
      getSecuredDomainObject in class BambooActionSupport
    • setAvailableBulkActions

      public void setAvailableBulkActions(List<BulkAction> availableBulkActions)
    • setRepositoryDefinitionManager

      public void setRepositoryDefinitionManager(RepositoryDefinitionManager repositoryDefinitionManager)
    • setActionProxyFactory

      public void setActionProxyFactory(com.opensymphony.xwork2.ActionProxyFactory actionProxyFactory)
    • setContainer

      public void setContainer(com.opensymphony.xwork2.inject.Container container)
      Overrides:
      setContainer in class com.opensymphony.xwork2.ActionSupport