SHARE
TWEET

What's Up with Logging in Java

a guest Feb 27th, 2012 20 Never
  1. logger.debug("The entry is {}.", entry);
  2. //which expands effectively to
  3. if (logger.isDebugEnabled()){
  4.     // Note that it's actually *more* efficient than this - see Huxi's comment below...
  5.     logger.debug("The entry is " + entry + ".");
  6. }
RAW Paste Data
Top