Returns the string specified by aKey from the errors.properties bundle.

@param aKey The key for the message pattern in the bundle.
@param arg The arg to use in the message format.
972365
public static String getString(String aKey, Object arg)
    {
        return getString(aKey,new Object[]{arg});
    }
169197
public static String format(final ResourceBundle bundle, final String key, final Object... arguments) {
		String pattern = ResourceBundles.getProperty(bundle, key);
		if (arguments.length == 0) {
			return pattern;
		}
		if (pattern.equals(key)) {
			return formatFallback(pattern, arguments);
		}
		return format(pattern, bundle.getLocale(), arguments);
	}
426032
public void error(String key, Object ... args) {
        error(diags.errorKey(key, args));
    }
1261
public static int checkArgPositive(final int arg, final String argNameOrErrorMsg) {
        if (arg <= 0) {
            if (argNameOrErrorMsg.indexOf(' ') == N.INDEX_NOT_FOUND) {
                throw new IllegalArgumentException("'" + argNameOrErrorMsg + "' can not be zero or negative: " + arg);
            } else {
                throw new IllegalArgumentException(argNameOrErrorMsg);
            }
        }

        return arg;
    }
1124268
@Configurable
  public void addArg(String arg)
  {
    if (_args == null)
      _args = new ArrayList<String>();
    
    _args.add(arg);
  }
845186
public static String checkNotEmpty(String arg, @Nullable Object errorMessage) {
    boolean empty = Strings.isNullOrEmpty(arg) || CharMatcher.whitespace().matchesAllOf(arg);
    checkArgument(!empty, errorMessage);
    return arg;
  }
710558
String messageFormat(String key, Object... args) {
        String rs = getResourceString(key);
        return MessageFormat.format(rs, args);
    }
333946
public void get(final String aBucket, final String aKey, final Handler<HttpClientResponse> aHandler) {
        createGetRequest(aBucket, aKey, aHandler).end();
    }
491749
@Override
    public void errormsg(String key, Object... args) {
        if (isRunningInteractive()) {
            rawout(prefixError(messageFormat(key, args)));
        } else {
            startmsg(key, args);
        }
    }
245626
function getBundlesForArgument(arg)
{
    // handles mix.bower(['package1', 'package2'])
    if (_.isArray(arg)) {
        return [new Bundle(arg)];
    }

    // handles mix.bower('namedBundle') where namedBundle is defined in bower.json
    if (_.isString(arg)) {
        return [new Bundle(BOWER_JSON.bundles[arg], arg)];
    }

    // handles mix.bower(), which uses all bundle definitions in bower.json
    if (BOWER_JSON.bundles && BOWER_JSON.bundles.length) {
        return _.map(BOWER_JSON.bundles || [], function (packages, name) {
            return new Bundle(packages, name);
        });
    }

    // handles mix.bower() when no "bundles" property, uses all from the
    // "dependencies" property as fallback
    if (BOWER_JSON.dependencies) {
        var packages = Object.keys(BOWER_JSON.dependencies);
        return [ new Bundle(packages) ];
    }

    return [];
}
228060
public void error(Enum<?> key, Object... args) {
        if (!logger.isErrorEnabled()) {
            return;
        }
        String translatedMsg = imc.getMessage(key, args);
        MessageParameterObj mpo = new MessageParameterObj(key, args);

        if (instanceofLAL) {
            ((LocationAwareLogger) logger).log(LOCALIZED, FQCN, LocationAwareLogger.ERROR_INT, translatedMsg, args, null);
        } else {
            logger.error(LOCALIZED, translatedMsg, mpo);
        }
    }
895290
public void error(String message, Object ... args) {
    if (log.isErrorEnabled()) {
      log.error(String.format(message, args));
    }
  }
669674
public void error (String msg, Object... args) {
    error(format(msg, args), getCause(args));
  }
1265660
private String getMessage(String key, Object... args) {
        String message = messages.getString(key);
        return (args.length == 0) ? message : MessageFormat.format(message, args);
    }
343409
protected final void addMessage(String msgKey, Object... args) {
    getFlash().addMessageNow(getTextInternal(msgKey, args));
  }
886348
public static FacesMessage getMessage(FacesMessage.Severity severity,
                                          String messageId,
                                          Object arg)
    {
        return getMessage(severity,
                          messageId,
                          new Object[]{arg},
                          FacesContext.getCurrentInstance());
    }
831975
public static Name getArgumentAsName(Object arg) {
        if (arg instanceof String) {
            return LdapUtils.newLdapName((String) arg);
        } else if (arg instanceof Name) {
            return (Name) arg;
        } else {
            throw new IllegalArgumentException(
                    "First argument needs to be a Name or a String representation thereof");
        }
    }