private static String setPrefixSuffix(String text, boolean prefix) throws ConfigurationException {
    text = text.trim();
    if (text.isEmpty()) return text;
    if (!StringUtil.isJavaIdentifier(text)) {
      final @Nls String message = JavaBundle.message(prefix
                                                     ? "code.style.generation.settings.error.not.valid.identifier.part.in.prefix"
                                                     : "code.style.generation.settings.error.not.valid.identifier.part.in.suffix", text);
      throw new ConfigurationException(message);
    }
    return text;
  }
private static String setPrefixSuffix(String text, boolean prefix)