01: /*
02: * XAPool: Open Source XA JDBC Pool
03: * Copyright (C) 2003 Objectweb.org
04: * Initial Developer: Lutris Technologies Inc.
05: * Contact: xapool-public@lists.debian-sf.objectweb.org
06: *
07: * This library is free software; you can redistribute it and/or
08: * modify it under the terms of the GNU Lesser General Public
09: * License as published by the Free Software Foundation; either
10: * version 2.1 of the License, or any later version.
11: *
12: * This library is distributed in the hope that it will be useful,
13: * but WITHOUT ANY WARRANTY; without even the implied warranty of
14: * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15: * Lesser General Public License for more details.
16: *
17: * You should have received a copy of the GNU Lesser General Public
18: * License along with this library; if not, write to the Free Software
19: * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
20: * USA
21: */
22: package org.enhydra.jdbc.util;
23:
24: import org.apache.commons.logging.Log;
25:
26: import java.io.PrintWriter;
27:
28: public class Logger extends PrintWriter {
29: private Log log;
30:
31: public Logger(Log log) {
32: super (new PrintWriter(System.err));
33: this .log = log;
34: }
35:
36: public void debug(Object o) {
37: log.debug(o);
38: }
39:
40: public void debug(Object o, Throwable t) {
41: log.debug(o, t);
42: }
43:
44: public void info(Object o) {
45: log.info(o);
46: }
47:
48: public void info(Object o, Throwable t) {
49: log.info(o, t);
50: }
51:
52: public void warn(Object o) {
53: log.warn(o);
54: }
55:
56: public void warn(Object o, Throwable t) {
57: log.warn(o, t);
58: }
59:
60: public void error(Object o) {
61: log.error(o);
62: }
63:
64: public void error(Object o, Throwable t) {
65: log.error(o, t);
66: }
67:
68: public void fatal(Object o) {
69: log.fatal(o);
70: }
71:
72: public void fatal(Object o, Throwable t) {
73: log.fatal(o, t);
74: }
75:
76: }
|