Class TriggerConfigurationUtils

java.lang.Object
com.atlassian.bamboo.trigger.TriggerConfigurationUtils

@Internal public class TriggerConfigurationUtils extends Object
  • Field Details

  • Method Details

    • removeTriggersFromConfig

      public static void removeTriggersFromConfig(org.apache.commons.configuration.HierarchicalConfiguration config)
      Removes all tasks from build configuration
      Parameters:
      config -
    • addTriggerDefinitionsToConfig

      public static void addTriggerDefinitionsToConfig(@Nullable @Nullable Iterable<TriggerDefinition> triggerDefinitions, @NotNull @NotNull org.apache.commons.configuration.HierarchicalConfiguration config)
      Adds tasks to a build configuration
      Parameters:
      triggerDefinitions -
      config -
    • getTriggerDefinitionsFromConfig

      @Nullable public static @Nullable com.google.common.collect.ImmutableList<TriggerDefinition> getTriggerDefinitionsFromConfig(org.apache.commons.configuration.HierarchicalConfiguration fromConfig)
      Retrieves tasks from build configuration
      Parameters:
      fromConfig -
      Returns:
    • extractTriggeringRepositoriesFromCfgString

      @NotNull public static @NotNull Set<Long> extractTriggeringRepositoriesFromCfgString(@NotNull @NotNull String triggeringRepositoriesString)
    • triggeringRepositoriesToString

      @NotNull public static @NotNull String triggeringRepositoriesToString(@NotNull @NotNull Set<Long> triggeringRepositories)
    • getTriggerDefinitionById

      @Nullable public static @Nullable TriggerDefinition getTriggerDefinitionById(@NotNull @NotNull Iterable<TriggerDefinition> triggers, long id)
    • getUniqueId

      public static long getUniqueId(@NotNull @NotNull List<TriggerDefinition> triggers)
      Returns id of trigger that is not used in provided list.
      Parameters:
      triggers -
      Returns:
    • getTriggerDefinitionsFromConfigNotNull

      @NotNull public static @NotNull com.google.common.collect.ImmutableList<TriggerDefinition> getTriggerDefinitionsFromConfigNotNull(org.apache.commons.configuration.HierarchicalConfiguration buildConfiguration)
    • updateRepositoryIdsInTriggers

      public static void updateRepositoryIdsInTriggers(List<TriggerDefinition> triggers, Map<Long,Long> repositoryIdsChanges)
    • removeRepositoryIdsFromTriggers

      public static void removeRepositoryIdsFromTriggers(List<TriggerDefinition> triggers, Set<Long> removedRepositoryIds)
    • triggerConditionsToConfiguration

      public static void triggerConditionsToConfiguration(org.apache.commons.configuration.HierarchicalConfiguration buildConfiguration, TriggerDefinition triggerDefinition)
    • extractTriggerConditionConfiguration

      public static Map<String,String> extractTriggerConditionConfiguration(org.apache.commons.configuration.HierarchicalConfiguration configuration)