public class PlanDependencyManagerImpl extends Object implements PlanDependencyManager
| Constructor and Description |
|---|
PlanDependencyManagerImpl(PlanDependencyDao planDependencyDao,
PlanManager planManager) |
| Modifier and Type | Method and Description |
|---|---|
void |
adjustChildDependencyList(String dependencyType,
Plan plan,
Set<PlanKey> newChildPlanKeys,
boolean overwriteExisting)
Update the existing children dependencies of the given plan and dependency Type to match the provided list of new children.
|
void |
adjustParentDependencyList(String dependencyKey,
Plan childPlan,
Set<PlanKey> newParentPlanKeys,
boolean overwriteExisting)
Update the existing parent dependencies of the given plan and dependency Type to match the provided list of new parents.
|
Set<PlanDependency> |
getAllDependencies()
Retrieves all dependency relationships in the system regardless of the plan involved
|
Set<String> |
getChildChainKeys(PlanIdentifier plan)
Retrieves all chain that are children of the current plan
|
Set<PlanDependency> |
getChildPlanDependencies(PlanIdentifier plan)
Retrieves all plan dependencies in which the given plan features as a parent
|
Set<String> |
getChildPlanKeys(PlanIdentifier plan)
Retrievs all plan that are children of the current plan
|
Set<ImmutablePlan> |
getEffectiveChildPlans(ImmutablePlan chain) |
Set<ImmutablePlan> |
getEffectiveParentPlans(ImmutablePlan chain) |
Set<String> |
getNotEditableChildKeys(PlanIdentifier plan)
Retrieves a list of keys representing the children that are not editable of the given plan
|
Set<String> |
getNotEditableParentKeys(PlanIdentifier plan)
Retrieves a list of keys representing the children that are not editable of the given plan
|
Set<String> |
getParentChainKeys(PlanIdentifier plan)
Retrieves all chain that are children of the current plan
|
Set<PlanDependency> |
getParentPlanDependencies(PlanIdentifier plan)
Retrieves all plan dependencies in which the given plan features as a child
|
Set<String> |
getParentPlanKeys(PlanIdentifier plan)
Retrievs all plans that are a parent of the current plan
|
void |
removeAllDependenciesForPlan(PlanIdentifier plan)
Deletes any existing dependency featuring the given plan.
|
boolean |
savePlanDependency(PlanDependency dependency)
Save the given dependency.
|
ErrorCollection |
validateChildDependencyList(String dependencyType,
Plan plan,
Set<PlanKey> newChildPlanKeys,
boolean overwriteExisting)
Validate child dependency list
|
@Inject public PlanDependencyManagerImpl(PlanDependencyDao planDependencyDao, PlanManager planManager)
@NotNull public Set<PlanDependency> getAllDependencies()
getAllDependencies in interface PlanDependencyManager@NotNull public Set<PlanDependency> getChildPlanDependencies(@NotNull PlanIdentifier plan)
PlanDependencyManagergetChildPlanDependencies in interface PlanDependencyManagerplan - - the parent@NotNull public Set<String> getParentChainKeys(@NotNull PlanIdentifier plan)
PlanDependencyManagergetParentChainKeys in interface PlanDependencyManagerplan - - the parent@NotNull public Set<String> getChildChainKeys(@NotNull PlanIdentifier plan)
PlanDependencyManagergetChildChainKeys in interface PlanDependencyManagerplan - - the parent@NotNull public Set<String> getNotEditableChildKeys(@NotNull PlanIdentifier plan)
PlanDependencyManagergetNotEditableChildKeys in interface PlanDependencyManagerplan - parent@NotNull public Set<String> getNotEditableParentKeys(@NotNull PlanIdentifier plan)
PlanDependencyManagergetNotEditableParentKeys in interface PlanDependencyManagerplan - parent@NotNull public Set<PlanDependency> getParentPlanDependencies(@NotNull PlanIdentifier plan)
PlanDependencyManagergetParentPlanDependencies in interface PlanDependencyManagerplan - - the childpublic void removeAllDependenciesForPlan(@NotNull
PlanIdentifier plan)
PlanDependencyManagerremoveAllDependenciesForPlan in interface PlanDependencyManagerplan - to be removed@NotNull public Set<String> getChildPlanKeys(@NotNull PlanIdentifier plan)
PlanDependencyManagergetChildPlanKeys in interface PlanDependencyManagerplan - - the parent@NotNull public Set<String> getParentPlanKeys(@NotNull PlanIdentifier plan)
PlanDependencyManagergetParentPlanKeys in interface PlanDependencyManagerplan - - the child@NotNull public ErrorCollection validateChildDependencyList(@NotNull String dependencyType, @NotNull Plan plan, @NotNull Set<PlanKey> newChildPlanKeys, boolean overwriteExisting)
PlanDependencyManagervalidateChildDependencyList in interface PlanDependencyManagerpublic void adjustChildDependencyList(@NotNull
String dependencyType,
@NotNull
Plan plan,
@NotNull
Set<PlanKey> newChildPlanKeys,
boolean overwriteExisting)
PlanDependencyManageradjustChildDependencyList in interface PlanDependencyManagerdependencyType - of the dependencies being adjustedplan - parentnewChildPlanKeys - the new list of parents (as plan keys)overwriteExisting - whether or not to overwrite any existing dependencies (of a different type) with one of the new typepublic void adjustParentDependencyList(@NotNull
String dependencyKey,
@NotNull
Plan childPlan,
@NotNull
Set<PlanKey> newParentPlanKeys,
boolean overwriteExisting)
PlanDependencyManageradjustParentDependencyList in interface PlanDependencyManagerdependencyKey - of the dependencies being adjustedchildPlan - parentnewParentPlanKeys - the new list of parents (as plan keys)overwriteExisting - whether or not to overwrite any existing dependencies (of a different type) with one of the new typepublic boolean savePlanDependency(@Nullable
PlanDependency dependency)
PlanDependencyManagersavePlanDependency in interface PlanDependencyManagerdependency - to savepublic Set<ImmutablePlan> getEffectiveChildPlans(@NotNull ImmutablePlan chain)
getEffectiveChildPlans in interface PlanDependencyManagerpublic Set<ImmutablePlan> getEffectiveParentPlans(@NotNull ImmutablePlan chain)
getEffectiveParentPlans in interface PlanDependencyManagerCopyright © 2019 Atlassian Software Systems Pty Ltd. All rights reserved.