public TestResourcesScope() { super(NAME, new AbstractPackageSet("test-rsc:*..*") { @Override public boolean contains(VirtualFile file, NamedScopesHolder holder) { final ProjectFileIndex index = ProjectRootManager.getInstance(holder.getProject()).getFileIndex(); return file != null && index.isInTestResource(file); } }); }
public ResourcesScope() { super(NAME, new AbstractPackageSet("rsc:*..*") { @Override public boolean contains(VirtualFile file, NamedScopesHolder holder) { final ProjectFileIndex index = ProjectRootManager.getInstance(holder.getProject()).getFileIndex(); return file != null && index.isInResource(file); } }); }
public SourcesScope() { super(NAME, new AbstractPackageSet("src:*..*") { @Override public boolean contains(VirtualFile file, NamedScopesHolder holder) { final ProjectFileIndex index = ProjectRootManager.getInstance(holder.getProject()).getFileIndex(); return file != null && index.isInSource(file); } }); }
public TestsScope() { super(NAME, new AbstractPackageSet("test:*..*") { @Override public boolean contains(VirtualFile file, NamedScopesHolder holder) { final ProjectFileIndex index = ProjectRootManager.getInstance(holder.getProject()).getFileIndex(); return file != null && index.isInTestSourceContent(file); } }); }
public ProjectProductionScope() { super(IdeBundle.message("predefined.scope.production.name"), new AbstractPackageSet("project:*..*") { @Override public boolean contains(VirtualFile file, NamedScopesHolder holder) { final ProjectFileIndex index = ProjectRootManager.getInstance(holder.getProject()).getFileIndex(); return file != null && !index.isInTestSourceContent(file) && !index.isInLibraryClasses(file) && !index.isInLibrarySource(file); } }); }