boolean (@NotNull VirtualFile file) { if (scope != null && !scope.contains(file)) { return true; } //e.g. xml files were not included in the graph, so usages there should be processed as external boolean inGraph = processedReferences ? refManager.isInGraph(file) : FileTypeRegistry.getInstance().isFileOfType(file, JavaFileType.INSTANCE); return !inGraph; }