@Override public void put(int msgLevel,String msg,Throwable ex){
  String exceptionText=null;
  if (ex != null) {
    StringWriter sw=new StringWriter();
    PrintWriter pw=new PrintWriter(sw);
    ex.printStackTrace(pw);
    pw.close();
    try {
      sw.close();
    }
 catch (    IOException ignore) {
    }
    exceptionText=sw.toString();
  }
  put(msgLevel,new Date(),this.connectionName,getThreadName(),getThreadId(),msg,exceptionText);
}

@ Override public void put ( int msgLevel , String msg , Throwable ex ) { String exceptionText = null ; if ( ex != null ) { StringWriter sw = new StringWriter ( ) ; PrintWriter pw = new PrintWriter ( sw ) ; ex . printStackTrace ( pw ) ; pw . close ( ) ; try { sw . close ( ) ; } catch ( IOException ignore ) { } exceptionText = sw . toString ( ) ; } put ( msgLevel , new Date ( ) , this . connectionName , getThreadName ( ) , getThreadId ( ) , msg , exceptionText ) ; }
logs a message and an exception to the specified log destination .
