@Override
  public boolean validate() throws ConfigurationException {
    final boolean validated = super.validate();
    if (!validated) {
      return false;
    }

    final List<ModuleDescriptor> modules = myModulesLayoutPanel.getChosenEntries();
    final Map<String, ModuleDescriptor> errors = new LinkedHashMap<>();
    for (ModuleDescriptor module : modules) {
      try {
        final String moduleFilePath = module.computeModuleFilePath();
        if (new File(moduleFilePath).exists()) {
          errors.put(JavaUiBundle.message("warning.message.the.module.file.0.already.exist.and.will.be.overwritten", moduleFilePath), module);
        }
      }
      catch (InvalidDataException e) {
        errors.put(e.getMessage(), module);
      }
    }
    if (!errors.isEmpty()) {
      final int answer = Messages.showYesNoCancelDialog(getComponent(),
                                                        JavaUiBundle.message("warning.text.0.do.you.want.to.overwrite.these.files",
                                                                          StringUtil.join(errors.keySet(), "\n"), errors.size()),
                                                        IdeBundle.message("title.file.already.exists"),
                                                        CommonBundle.message("button.overwrite"),
                                                        CommonBundle.message("button.reuse"),
                                                        CommonBundle.message("button.without.mnemonics.cancel"), Messages.getQuestionIcon());
      if (answer == Messages.CANCEL) {
        return false;
      }

      if (answer != Messages.YES) {
        for (ModuleDescriptor moduleDescriptor : errors.values()) {
          moduleDescriptor.reuseExisting(true);
        }
      }
    }
    return true;
  }
@Override
  public boolean validate()