Interface Chain

All Superinterfaces:
BambooIdProvider, BambooObject, BambooObjectWithOid, Deletable, Describable, DescriptionProvider, EntityWithOid, ImmutableChain, ImmutableDeletable, ImmutableEntityWithOid, ImmutablePlan, NameProvider, Plan, PlanIdentifier, PlanKeyProvider, Triggerable, Versionable
All Known Subinterfaces:
ChainBranch, TopLevelPlan
All Known Implementing Classes:
AbstractChain, ChainBranchImpl, DefaultChain

@PublicApi public interface Chain extends ImmutableChain, Plan
Mutable version of ImmutableChain.
  • Method Details

    • setNotificationSet

      void setNotificationSet(NotificationSet notificationSet)
    • addNewStage

      @Deprecated @NotNull @NotNull ChainStage addNewStage(@NotNull @NotNull String name, @NotNull @NotNull String description, boolean manual)
      Deprecated.
      since 5.13 use addStage(ChainStage)
      Adds a new stage and returns the stage
      Parameters:
      name -
      description -
      manual -
      Returns:
    • addStage

      void addStage(@NotNull @NotNull ChainStage chainStage)
    • addStage

      void addStage(int index, @NotNull @NotNull ChainStage chainStage)
      Add stage at given index.
      Since:
      7.2
    • removeStage

      void removeStage(long chainStageId)
    • getMaster

      Chain getMaster()
      Description copied from interface: ImmutablePlan
      Return the master plan if one exists. The master is the plan which this one is derived from. Configuration is pulled from the master if one exists.
      Specified by:
      getMaster in interface ImmutableChain
      Specified by:
      getMaster in interface ImmutablePlan
      Returns:
      the master Plan if one exists.
    • getStages

      @NotNull @NotNull List<ChainStage> getStages()
      Description copied from interface: ImmutableChain
      Get Stages of the chain.

      Note that this excludes ChainStages that have been marked for deletion

      Specified by:
      getStages in interface ImmutableChain
      Returns:
      stages
    • getAllStages

      @NotNull @NotNull List<ChainStage> getAllStages()
      Get Stages of the Chain

      Note that this includes ChainStages that have been marked for deletion

      Specified by:
      getAllStages in interface ImmutableChain
      Returns:
      unmodifiable list of all stages
    • getAllJobs

      @NotNull @NotNull List<Job> getAllJobs()
      Note: Does not include Jobs that are marked for deletion.
      Specified by:
      getAllJobs in interface ImmutableChain
      Returns:
      a list of all Jobs that are currently contained within this chain - no order guaranteed.
    • setStorageTag

      void setStorageTag(ChainStorageTag storageTag)
    • removeStagesIf

      void removeStagesIf(@NotNull @NotNull Predicate<ChainStage> predicate)
      Remove all stages matching a predicate.
      Since:
      7.1