public void testResolveFileReference() throws Exception { configureByFile(BASE_PATH + "C.java", BASE_PATH); FileIncludeManager fileIncludeManager = FileIncludeManager.getManager(getProject()); PsiFileSystemItem item = fileIncludeManager.resolveFileInclude(new FileIncludeInfo("x/MyFile.txt"), getFile()); assertNotNull(item); assertEquals("MyFile.txt", item.getName()); }
public static boolean processForwardDependencies(XmlFile file, final PsiElementProcessor<XmlFile> processor) { VirtualFile virtualFile = file.getVirtualFile(); if (virtualFile == null) { return processor.execute(file); } final Project project = file.getProject(); final VirtualFile[] files = FileIncludeManager.getManager(project).getIncludedFiles(virtualFile, true); return processRelatedFiles(file, files, processor); }
public static boolean processBackwardDependencies(@NotNull XmlFile file, PsiElementProcessor<XmlFile> processor) { VirtualFile virtualFile = file.getVirtualFile(); if (virtualFile == null) { return processor.execute(file); } final Project project = file.getProject(); final VirtualFile[] files = FileIncludeManager.getManager(project).getIncludingFiles(virtualFile, true); return processRelatedFiles(file, files, processor); }
public static boolean processForwardDependencies(@NotNull XmlFile file, Processor<XmlFile> processor) { final VirtualFile virtualFile = file.getVirtualFile(); if (virtualFile == null) { return true; } final Project project = file.getProject(); final VirtualFile[] files = FileIncludeManager.getManager(project).getIncludedFiles(virtualFile, true); return _process(files, project, processor); }
public static boolean processBackwardDependencies(@NotNull XmlFile file, Processor<XmlFile> processor) { final VirtualFile virtualFile = file.getVirtualFile(); if (virtualFile == null) { return true; } final Project project = file.getProject(); final VirtualFile[] files = FileIncludeManager.getManager(project).getIncludingFiles(virtualFile, true); return _process(files, project, processor); }
public FileIncludeContextHectorPanel(final PsiFile file, final FileIncludeManager includeManager) { myFile = file; myIncludeManager = includeManager; reset(); }
public FileIncludeContextHectorProvider(final FileIncludeManager includeManager) { myIncludeManager = includeManager; }
public static boolean isReachableFrom(XmlFile which, XmlFile from) { return from == which || _isReachableFrom(from.getVirtualFile(), FileIncludeManager.getManager(which.getProject()).getIncludingFiles(which.getVirtualFile(), true)); }