use of org.gradle.api.internal.artifacts.DefaultProjectComponentIdentifier in project gradle by gradle.
the class AbstractCompositeParticipantBuildState method registerProject.
private void registerProject(Set<Pair<ModuleVersionIdentifier, ProjectComponentIdentifier>> availableModules, ProjectInternal project) {
ProjectComponentIdentifier projectIdentifier = new DefaultProjectComponentIdentifier(getBuildIdentifier(), project.getIdentityPath(), project.getProjectPath(), project.getName());
ModuleVersionIdentifier moduleId = DefaultModuleVersionIdentifier.newId(project.getDependencyMetaDataProvider().getModule());
LOGGER.info("Registering {} in composite build. Will substitute for module '{}'.", project, moduleId.getModule());
availableModules.add(Pair.of(moduleId, projectIdentifier));
}
use of org.gradle.api.internal.artifacts.DefaultProjectComponentIdentifier in project gradle by gradle.
the class DefaultProjectStateRegistry method addProject.
private ProjectState addProject(BuildState owner, DefaultBuildProjectRegistry projectRegistry, DefaultProjectDescriptor descriptor) {
Path projectPath = descriptor.path();
Path identityPath = owner.calculateIdentityPathForProject(projectPath);
String name = descriptor.getName();
ProjectComponentIdentifier projectIdentifier = new DefaultProjectComponentIdentifier(owner.getBuildIdentifier(), identityPath, projectPath, name);
IProjectFactory projectFactory = owner.getMutableModel().getServices().get(IProjectFactory.class);
StateTransitionControllerFactory stateTransitionControllerFactory = owner.getMutableModel().getServices().get(StateTransitionControllerFactory.class);
ProjectStateImpl projectState = new ProjectStateImpl(owner, identityPath, projectPath, descriptor.getName(), projectIdentifier, descriptor, projectFactory, stateTransitionControllerFactory);
projectsByPath.put(identityPath, projectState);
projectsById.put(projectIdentifier, projectState);
projectRegistry.add(projectPath, projectState);
return projectState;
}
Aggregations