mina-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From trus...@apache.org
Subject svn commit: r547097 - /mina/trunk/core/src/main/java/org/apache/mina/util/SessionLog.java
Date Thu, 14 Jun 2007 02:56:39 GMT
Author: trustin
Date: Wed Jun 13 19:56:39 2007
New Revision: 547097

URL: http://svn.apache.org/viewvc?view=rev&rev=547097
Log:
Added more convenient logging methods for unexpected exceptions.

Modified:
    mina/trunk/core/src/main/java/org/apache/mina/util/SessionLog.java

Modified: mina/trunk/core/src/main/java/org/apache/mina/util/SessionLog.java
URL: http://svn.apache.org/viewvc/mina/trunk/core/src/main/java/org/apache/mina/util/SessionLog.java?view=diff&rev=547097&r1=547096&r2=547097
==============================================================================
--- mina/trunk/core/src/main/java/org/apache/mina/util/SessionLog.java (original)
+++ mina/trunk/core/src/main/java/org/apache/mina/util/SessionLog.java Wed Jun 13 19:56:39
2007
@@ -116,6 +116,10 @@
             log.warn( String.valueOf( getPrefix( session ) ) + message );
         }
     }
+    
+    public static void warn(IoSession session, Throwable cause) {
+        warn(session, "Unexpected exception.", cause);
+    }
 
     public static void warn( IoSession session, String message, Throwable cause )
     {
@@ -141,6 +145,10 @@
         {
             log.error( String.valueOf( getPrefix( session ) ) + message );
         }
+    }
+
+    public static void error(IoSession session, Throwable cause) {
+        error(session, "Unexpected exception.", cause);
     }
 
     public static void error( IoSession session, String message, Throwable cause )



Mime
View raw message