@Override
  public void invoke(@NotNull Project project, Editor editor, PsiFile file) throws IncorrectOperationException {
    JavaSdkVersion required = JavaSdkVersion.fromLanguageLevel(myLevel);
    SdkPopupFactory
      .newBuilder()
      .withProject(project)
      .withSdkTypeFilter(type -> type instanceof JavaSdkType)
      .withSdkFilter(sdk -> JavaSdkVersionUtil.getJavaSdkVersion(sdk).isAtLeast(required))
      .updateSdkForFile(file)
      .onSdkSelected(sdk -> ApplicationManager.getApplication()
        .invokeLater(() -> new IncreaseLanguageLevelFix(myLevel)
        .invoke(project, editor, file), ModalityState.nonModal(), project.getDisposed()))
      .buildPopup()
      .showInBestPositionFor(editor);
  }
@Override
  public void invoke(@NotNull Project project, Editor editor, PsiFile file)