List<FileInfo> (final Project project, final String fileName, final boolean includeNonProjectItems) { final List<FileInfo> filesInfo = new ArrayList<>(); for (ChooseByNameContributor contributor : ChooseByNameContributor.FILE_EP_NAME.getExtensionList()) { // let's find files with same name in project and libraries final NavigationItem[] navigationItems = contributor.getItemsByName(fileName, fileName, project, includeNonProjectItems); for (NavigationItem navigationItem : navigationItems) { if (navigationItem instanceof PsiFile) { final VirtualFile itemFile = ((PsiFile)navigationItem).getVirtualFile(); assert itemFile != null; filesInfo.add(new FileInfo(itemFile)); } } } return filesInfo; }