ExternalProjectDependency (@NotNull ResolvedDependency resolvedDependency, @NotNull Map<ModuleVersionIdentifier, ResolvedDependencyResult> transformedProjectDependenciesResultMap, @NotNull Map<String, DefaultExternalProjectDependency> resolvedProjectDependencies, @Nullable String scope) { ModuleVersionIdentifier moduleVersionIdentifier = resolvedDependency.getModule().getId(); ResolvedDependencyResult resolvedDependencyResult = transformedProjectDependenciesResultMap.get(moduleVersionIdentifier); if (resolvedDependencyResult == null) return null; ProjectComponentSelector dependencyResultRequested = (ProjectComponentSelector)resolvedDependencyResult.getRequested(); String projectPath = dependencyResultRequested.getProjectPath(); String key = projectPath + "_" + resolvedDependency.getConfiguration(); DefaultExternalProjectDependency projectDependency = resolvedProjectDependencies.get(key); if (projectDependency != null) return null; projectDependency = new DefaultExternalProjectDependency(); resolvedProjectDependencies.put(key, projectDependency); String projectName = Path.path(projectPath).getName(); projectDependency.setName(projectName); projectDependency.setGroup(resolvedDependency.getModuleGroup()); projectDependency.setVersion(resolvedDependency.getModuleVersion()); projectDependency.setScope(scope); projectDependency.setProjectPath(projectPath); projectDependency.setConfigurationName(resolvedDependency.getConfiguration()); Project project = myProject.findProject(projectPath); if (project == null) return null; Configuration configuration1 = project.getConfigurations().findByName(resolvedDependency.getConfiguration()); if (configuration1 == null) return null; Set<File> projectArtifacts = configuration1.getArtifacts().getFiles().getFiles(); projectDependency.setProjectDependencyArtifacts(projectArtifacts); GradleSourceSetCachedFinder sourceSetFinder = GradleSourceSetCachedFinder.getInstance(myContext); projectDependency.setProjectDependencyArtifactsSources(sourceSetFinder.findArtifactSources(projectArtifacts)); return projectDependency; }