@NotNull
  public JavaRunConfigurationModule checkClass() throws RuntimeConfigurationException {
    final JavaRunConfigurationModule configurationModule = getConfigurationModule();
    final String mainClass = getMainClassName();
    if (getOptions().isImplicitClassConfiguration()) {
      if (mainClass != null && !DumbService.isDumb(getProject())) {
        try {
          final boolean matchingClass = !JavaImplicitClassIndex.getInstance()
            .getElements(mainClass, getProject(), configurationModule.getSearchScope())
            .isEmpty();
          if (!matchingClass) {
            throw new RuntimeConfigurationWarning(ExecutionBundle.message("main.method.not.found.in.class.error.message", mainClass));
          }
        } catch (IndexNotReadyException ignored) {}
      }
    } else {
      final PsiClass psiClass = configurationModule.checkModuleAndClassName(mainClass, ExecutionBundle.message("no.main.class.specified.error.text"));
      if (psiClass == null || !PsiMethodUtil.hasMainMethod(psiClass)) {
        throw new RuntimeConfigurationWarning(ExecutionBundle.message("main.method.not.found.in.class.error.message", mainClass));
      }
    }
    return configurationModule;
  }
@NotNull
  public JavaRunConfigurationModule checkClass()