public LogFormatter(Logger log){
  if (log == null)   log=Logger.getLogger(Logger.GLOBAL_LOGGER_NAME);
  Level lvl=null;
  while (log != null) {
    lvl=log.getLevel();
    if (lvl != null)     break;
    log=log.getParent();
  }
  ;
  if (lvl == null)   lvl=Level.WARNING;
  this.level=lvl;
}

public LogFormatter ( Logger log ) { if ( log == null ) log = Logger . getLogger ( Logger . GLOBAL_LOGGER_NAME ) ; Level lvl = null ; while ( log != null ) { lvl = log . getLevel ( ) ; if ( lvl != null ) break ; log = log . getParent ( ) ; } ; if ( lvl == null ) lvl = Level . WARNING ; this . level = lvl ; }
create a log formatter around a given logger . if null , uses the global logger .
