1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16 package org.jboss.netty.logging;
17
18 import org.jboss.logging.Logger;
19
20
21
22
23
24 class JBossLogger extends AbstractInternalLogger {
25
26 private final Logger logger;
27
28 JBossLogger(Logger logger) {
29 this.logger = logger;
30 }
31
32 public void debug(String msg) {
33 logger.debug(msg);
34 }
35
36 public void debug(String msg, Throwable cause) {
37 logger.debug(msg, cause);
38 }
39
40 public void error(String msg) {
41 logger.error(msg);
42 }
43
44 public void error(String msg, Throwable cause) {
45 logger.error(msg, cause);
46 }
47
48 public void info(String msg) {
49 logger.info(msg);
50 }
51
52 public void info(String msg, Throwable cause) {
53 logger.info(msg, cause);
54 }
55
56 @SuppressWarnings("deprecation")
57 public boolean isDebugEnabled() {
58 return logger.isDebugEnabled();
59 }
60
61 public boolean isErrorEnabled() {
62 return true;
63 }
64
65 @SuppressWarnings("deprecation")
66 public boolean isInfoEnabled() {
67 return logger.isInfoEnabled();
68 }
69
70 public boolean isWarnEnabled() {
71 return true;
72 }
73
74 public void warn(String msg) {
75 logger.warn(msg);
76 }
77
78 public void warn(String msg, Throwable cause) {
79 logger.warn(msg, cause);
80 }
81
82 @Override
83 public String toString() {
84 return String.valueOf(logger.getName());
85 }
86 }