01: package com.ibatis.common.logging.log4j;
02:
03: import org.apache.log4j.Logger;
04:
05: public class Log4jImpl implements com.ibatis.common.logging.Log {
06:
07: private Logger log;
08:
09: public Log4jImpl(Class clazz) {
10: log = Logger.getLogger(clazz);
11: }
12:
13: public boolean isDebugEnabled() {
14: return log.isDebugEnabled();
15: }
16:
17: public void error(String s, Throwable e) {
18: log.error(s, e);
19: }
20:
21: public void error(String s) {
22: log.error(s);
23: }
24:
25: public void debug(String s) {
26: log.debug(s);
27: }
28:
29: public void warn(String s) {
30: log.warn(s);
31: }
32:
33: }
|