mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-03-22 15:19:59 +07:00
[java, highlighting, jigsaw] find module descriptor: support exclusions IDEA-354700
GitOrigin-RevId: ee96fec82905611a18aec82fd8554f7fb7d1dbb2
This commit is contained in:
committed by
intellij-monorepo-bot
parent
d5b64de3db
commit
df7529c232
@@ -175,6 +175,9 @@ public final class JavaModuleGraphUtil {
|
||||
JavaSourceRootType rootType = inTests ? JavaSourceRootType.TEST_SOURCE : JavaSourceRootType.SOURCE;
|
||||
ModuleRootManager rootManager = ModuleRootManager.getInstance(module);
|
||||
List<VirtualFile> sourceRoots = rootManager.getSourceRoots(rootType);
|
||||
Set<VirtualFile> excludeRoots = ContainerUtil.newHashSet(ModuleRootManager.getInstance(module).getExcludeRoots());
|
||||
if (!excludeRoots.isEmpty()) sourceRoots.removeIf(root -> excludeRoots.contains(root));
|
||||
|
||||
List<VirtualFile> files = ContainerUtil.mapNotNull(sourceRoots, root -> root.findChild(PsiJavaModule.MODULE_INFO_FILE));
|
||||
if (files.isEmpty()) {
|
||||
JavaResourceRootType resourceRootType = inTests ? JavaResourceRootType.TEST_RESOURCE : JavaResourceRootType.RESOURCE;
|
||||
|
||||
Reference in New Issue
Block a user