use of org.gradle.tooling.model.GradleProject in project intellij-community by JetBrains.
the class GradleProjectResolverUtil method getModuleId.
@NotNull
public static String getModuleId(@NotNull ProjectResolverContext resolverCtx, @NotNull IdeaModule gradleModule) {
GradleProject gradleProject = gradleModule.getGradleProject();
String gradlePath = gradleProject.getPath();
String compositePrefix = "";
if (gradleModule.getProject() != resolverCtx.getModels().getIdeaProject()) {
if (!StringUtil.isEmpty(gradlePath) && !":".equals(gradlePath)) {
compositePrefix = gradleModule.getProject().getName();
}
}
return compositePrefix + getModuleId(gradlePath, gradleModule.getName());
}
use of org.gradle.tooling.model.GradleProject in project gradle by gradle.
the class FetchIncludedGradleProjects method execute.
@Override
public List<GradleProject> execute(BuildController controller) {
List<GradleProject> projects = new ArrayList<GradleProject>();
GradleBuild build = controller.getBuildModel();
for (GradleBuild includedBuild : build.getIncludedBuilds()) {
projects.add(controller.getModel(includedBuild, GradleProject.class));
}
return projects;
}
Aggregations