boolean (@Nullable String homePath) { if (StringUtil.isEmptyOrSpaces(homePath)) { return false; } try { return JdkUtil.checkForJdk(homePath) && JdkUtil.checkForJre(homePath); } catch (InvalidPathException exception) { return false; } }