KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > com > ibatis > common > logging > log4j > Log4jImpl


1 package com.ibatis.common.logging.log4j;
2
3 import org.apache.log4j.Logger;
4
5 public class Log4jImpl implements com.ibatis.common.logging.Log {
6
7   private Logger log;
8
9   public Log4jImpl(Class JavaDoc clazz) {
10      log = Logger.getLogger(clazz);
11   }
12
13   public boolean isDebugEnabled() {
14     return log.isDebugEnabled();
15   }
16
17   public void error(String JavaDoc s, Exception JavaDoc e) {
18     log.error(s, e);
19   }
20
21   public void debug(String JavaDoc s) {
22     log.debug(s);
23   }
24
25   public void warn(String JavaDoc s) {
26     log.warn(s);
27   }
28
29
30 }
31
Popular Tags