com.atlassian.bamboo.build
Interface BuildTriggerCondition

All Superinterfaces:
BambooPluginModule, BuildConfigurationAwarePlugin, InitablePluginModule, RenderableBuildConfiguration
All Known Implementing Classes:
PlansGreenCondition

public interface BuildTriggerCondition
extends BuildConfigurationAwarePlugin

Provides the ability to gate whether a build should be triggered or not. Uses a preference system so plugins can behave nicer with each other.


Nested Class Summary
static class BuildTriggerCondition.ExecutionPreference
           
 
Method Summary
 java.util.Map<java.lang.String,java.lang.String> getConfigurationMap(org.apache.commons.configuration.HierarchicalConfiguration configuration)
          This method should extract entire configuration of this plugin from HierarchicalConfiguration and return it as map.
 BuildTriggerCondition.ExecutionPreference getExecutionPreference(ImmutablePlan plan)
          Deprecated. since 4.3 use getExecutionPreference(ImmutablePlan, Map)
 BuildTriggerCondition.ExecutionPreference getExecutionPreference(ImmutablePlan plan, java.util.Map<java.lang.String,java.lang.String> configuration)
          Use to indicate preference for whether this plugin things the plan should execute.
 
Methods inherited from interface com.atlassian.bamboo.v2.build.BuildConfigurationAwarePlugin
addDefaultValues, prepareConfigObject, validate
 
Methods inherited from interface com.atlassian.bamboo.plugin.InitablePluginModule
init
 
Methods inherited from interface com.atlassian.bamboo.v2.build.RenderableBuildConfiguration
getEditHtml, getViewHtml
 

Method Detail

getConfigurationMap

@NotNull
java.util.Map<java.lang.String,java.lang.String> getConfigurationMap(@NotNull
                                                                             org.apache.commons.configuration.HierarchicalConfiguration configuration)
This method should extract entire configuration of this plugin from HierarchicalConfiguration and return it as map.

Parameters:
configuration - a configuration
Returns:
complete configuration of the plugin as a string map
Since:
4.3

getExecutionPreference

@NotNull
@Deprecated
BuildTriggerCondition.ExecutionPreference getExecutionPreference(ImmutablePlan plan)
Deprecated. since 4.3 use getExecutionPreference(ImmutablePlan, Map)

Use to indicate preference for whether this plugin thinks the plan should execute. Whether the build actually will execute will follow the above order

Parameters:
plan - the plan that will be executed
Returns:
the execution preference of this plan, will be overridden if another plugin returns with a higher preference

getExecutionPreference

@NotNull
BuildTriggerCondition.ExecutionPreference getExecutionPreference(ImmutablePlan plan,
                                                                         java.util.Map<java.lang.String,java.lang.String> configuration)
Use to indicate preference for whether this plugin things the plan should execute. Whether the build actually will execute will follow the above order

Parameters:
plan - the plan that will be executed
configuration - of the plugin as returned by getConfigurationMap(HierarchicalConfiguration)
Returns:
the execution preference of this plan, will be overridden if another plugin returns with a higher preference
Since:
4.3


Copyright © 2013 Atlassian Software Systems Pty Ltd. All Rights Reserved.