boolean (@NotNull VirtualFile file) { if (!file.isDirectory() && FileTypeRegistry.getInstance().isFileOfType(file, XmlFileType.INSTANCE)) { PsiFile psiFile = fileManager.getCachedPsiFile(file); DomFileElementImpl<?> domElement = psiFile instanceof XmlFile ? getCachedFileElement((XmlFile)psiFile) : null; if (domElement != null) { events.add(new DomEvent(domElement, false)); } } return true; }