boolean (@NotNull PsiFile file) { return file instanceof PsiJavaFile && CachedValuesManager.getCachedValue(file, () -> { PsiImportList importList = ((PsiJavaFile)file).getImportList(); boolean javafx = importList != null && ContainerUtil.exists(importList.getAllImportStatements(), s -> { PsiJavaCodeReferenceElement ref = s.getImportReference(); String qualifiedName = ref != null ? ref.getQualifiedName() : null; return qualifiedName != null && qualifiedName.startsWith("javafx.") && ref.resolve() != null; }); return CachedValueProvider.Result.create(javafx, PsiModificationTracker.MODIFICATION_COUNT); }); }