commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Achim Felber <>
Subject Re: [logging] LogConfigurationException
Date Fri, 06 Jun 2003 03:15:58 GMT
Are there any opinions regarding the lack of log method such as

  public void log(String msg, Object[] parameters, Throwable ex)
    if (logger.isEnabled())
	    logger.log(java.text.MessageFormat.format(msg, parameters), ex)

This method would only create the string to log if the logger is
actually enabled. Also, it might make it easier to internationalize the
code since the strings to change may be easier to locate.

Any pros and cons to this approach?

Achim Felber

View raw message