Search in sources :

Example 1 with BuildDependency

use of jetbrains.buildServer.serverSide.dependency.BuildDependency in project teamcity-rest by JetBrains.

the class Build method getBuildPromotions.

static List<BuildPromotion> getBuildPromotions(@NotNull Collection<? extends BuildDependency> dependencies) {
    List<BuildPromotion> result = new ArrayList<BuildPromotion>(dependencies.size());
    for (BuildDependency dependency : dependencies) {
        result.add(dependency.getDependOn());
    }
    Collections.sort(result, new BuildPromotionDependenciesComparator());
    return result;
}
Also used : BuildDependency(jetbrains.buildServer.serverSide.dependency.BuildDependency)

Example 2 with BuildDependency

use of jetbrains.buildServer.serverSide.dependency.BuildDependency in project teamcity-rest by JetBrains.

the class Build method getBuilds.

static List<SBuild> getBuilds(@NotNull Collection<? extends BuildDependency> dependencies) {
    List<SBuild> result = new ArrayList<SBuild>(dependencies.size());
    for (BuildDependency dependency : dependencies) {
        final SBuild dependOnBuild = dependency.getDependOn().getAssociatedBuild();
        if (dependOnBuild != null) {
            result.add(dependOnBuild);
        }
    }
    Collections.sort(result, new BuildDependenciesComparator());
    return result;
}
Also used : BuildDependency(jetbrains.buildServer.serverSide.dependency.BuildDependency)

Aggregations

BuildDependency (jetbrains.buildServer.serverSide.dependency.BuildDependency)2