@Override
  public @NotNull Sdk createJdk(@NotNull String jdkName, @NotNull String home, boolean isJre) {
    Path jdkHomePath = Path.of(home);
    if (!Files.exists(jdkHomePath)) {
      throw new IllegalArgumentException(jdkHomePath.toAbsolutePath() + " doesn't exist");
    }

    Sdk jdk = ProjectJdkTable.getInstance().createSdk(jdkName, this);
    SdkModificator sdkModificator = jdk.getSdkModificator();

    sdkModificator.setHomePath(FileUtil.toSystemIndependentName(home));
    if (JdkVersionDetector.isVersionString(jdkName)) {
      sdkModificator.setVersionString(jdkName);  // must be set after the home path, otherwise setting a home path clears the version string
    }
    else {
      sdkModificator.setVersionString(this.getVersionString(home));
    }

    addClasses(jdkHomePath, sdkModificator, isJre);
    addSources(jdkHomePath, sdkModificator);
    addDocs(jdkHomePath, sdkModificator, null);
    attachJdkAnnotations(sdkModificator);

    sdkModificator.applyChangesWithoutWriteAction();
    return jdk;
  }
@Override
  public @NotNull Sdk createJdk(@NotNull String jdkName, @NotNull String home, boolean isJre)