1 19 20 package org.apache.avalon.cornerstone.blocks.connection; 21 22 import org.apache.commons.logging.LogFactory; 23 24 import java.io.IOException ; 25 26 32 public class CommonsLoggingConnectionMonitor implements ConnectionMonitor 33 { 34 35 public void acceptingConnectionException(Class clazz, String message, IOException ioe) 36 { 37 LogFactory.getLog(clazz).error(message, ioe); 38 } 39 40 public void unexpectedException(Class clazz, String message, Exception e) 41 { 42 LogFactory.getLog(clazz).error(message, e); 43 } 44 45 public void shutdownSocketWarning(Class clazz, String message, IOException ioe) 46 { 47 LogFactory.getLog(clazz).error(message, ioe); 48 } 49 50 public void debugMessage(Class clazz, String message) 51 { 52 LogFactory.getLog(clazz).error(message); 53 } 54 55 public boolean isDebugEnabled(Class clazz) 56 { 57 return LogFactory.getLog(clazz).isDebugEnabled(); 58 } 59 } 60 | Popular Tags |