Class DefaultTriggerConditionExporter
- java.lang.Object
-
- com.atlassian.bamboo.trigger.export.DefaultTriggerConditionExporter
-
- All Implemented Interfaces:
BuildTriggerConditionExporter<com.atlassian.bamboo.specs.api.model.trigger.TriggerConditionProperties>
public class DefaultTriggerConditionExporter extends Object implements BuildTriggerConditionExporter<com.atlassian.bamboo.specs.api.model.trigger.TriggerConditionProperties>
-
-
Constructor Summary
Constructors Constructor Description DefaultTriggerConditionExporter()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description @Nullable com.atlassian.bamboo.specs.api.builders.trigger.TriggerCondition
fromYaml(@NotNull Node node)
Set<String>
getConfigurationKeys()
@NotNull Map<String,String>
toConfigurationMap(@NotNull com.atlassian.bamboo.specs.api.model.trigger.TriggerConditionProperties properties)
<T extends com.atlassian.bamboo.specs.api.builders.trigger.TriggerCondition<T,com.atlassian.bamboo.specs.api.model.trigger.TriggerConditionProperties>>
TtoSpecsEntity(@NotNull Map<String,String> triggerConditionConfigurations)
It's a requirement to return null here as we don't want default condition exporter handle raw map of trigger conditions map.@Nullable Node
toYaml(@NotNull com.atlassian.bamboo.specs.api.model.trigger.TriggerConditionProperties triggerConditionProperties)
@NotNull List<com.atlassian.bamboo.specs.api.validators.common.ValidationProblem>
validate(TriggerValidationContext validationContext, com.atlassian.bamboo.specs.api.model.trigger.TriggerConditionProperties condition)
-
-
-
Method Detail
-
getConfigurationKeys
public Set<String> getConfigurationKeys()
- Specified by:
getConfigurationKeys
in interfaceBuildTriggerConditionExporter<com.atlassian.bamboo.specs.api.model.trigger.TriggerConditionProperties>
- Returns:
- config keys which exporter expect at configuration map.
-
toSpecsEntity
@Nullable public <T extends com.atlassian.bamboo.specs.api.builders.trigger.TriggerCondition<T,com.atlassian.bamboo.specs.api.model.trigger.TriggerConditionProperties>> T toSpecsEntity(@NotNull @NotNull Map<String,String> triggerConditionConfigurations)
It's a requirement to return null here as we don't want default condition exporter handle raw map of trigger conditions map.- Specified by:
toSpecsEntity
in interfaceBuildTriggerConditionExporter<com.atlassian.bamboo.specs.api.model.trigger.TriggerConditionProperties>
- Returns:
- Specs builder.
-
toConfigurationMap
@NotNull public @NotNull Map<String,String> toConfigurationMap(@NotNull @NotNull com.atlassian.bamboo.specs.api.model.trigger.TriggerConditionProperties properties)
- Specified by:
toConfigurationMap
in interfaceBuildTriggerConditionExporter<com.atlassian.bamboo.specs.api.model.trigger.TriggerConditionProperties>
- Returns:
- trigger condition configuration map extracted from TriggerConditionProperties.
-
validate
@NotNull public @NotNull List<com.atlassian.bamboo.specs.api.validators.common.ValidationProblem> validate(TriggerValidationContext validationContext, com.atlassian.bamboo.specs.api.model.trigger.TriggerConditionProperties condition)
- Specified by:
validate
in interfaceBuildTriggerConditionExporter<com.atlassian.bamboo.specs.api.model.trigger.TriggerConditionProperties>
-
toYaml
@Nullable public @Nullable Node toYaml(@NotNull @NotNull com.atlassian.bamboo.specs.api.model.trigger.TriggerConditionProperties triggerConditionProperties)
- Specified by:
toYaml
in interfaceBuildTriggerConditionExporter<com.atlassian.bamboo.specs.api.model.trigger.TriggerConditionProperties>
-
fromYaml
@Nullable public @Nullable com.atlassian.bamboo.specs.api.builders.trigger.TriggerCondition fromYaml(@NotNull @NotNull Node node)
- Specified by:
fromYaml
in interfaceBuildTriggerConditionExporter<com.atlassian.bamboo.specs.api.model.trigger.TriggerConditionProperties>
- Returns:
- Specs builder.
-
-