1
2
3
4
5
6
7
8 package org.codehaus.dna;
9
10 /***
11 * This interface was a facade for different Logger subsystems.
12 *
13 * @version $Revision: 1.2 $ $Date: 2004/05/01 09:51:48 $
14 */
15 public interface Logger
16 {
17 /***
18 * Log a trace message.
19 *
20 * @param message the message
21 */
22 void trace( String message );
23
24 /***
25 * Log a trace message with an associated throwable.
26 *
27 * @param message the message
28 * @param throwable the throwable
29 */
30 void trace( String message, Throwable throwable );
31
32 /***
33 * Return true if a trace message will be logged.
34 *
35 * @return true if message will be logged
36 */
37 boolean isTraceEnabled();
38
39 /***
40 * Log a debug message.
41 *
42 * @param message the message
43 */
44 void debug( String message );
45
46 /***
47 * Log a debug message with an associated throwable.
48 *
49 * @param message the message
50 * @param throwable the throwable
51 */
52 void debug( String message, Throwable throwable );
53
54 /***
55 * Return true if a debug message will be logged.
56 *
57 * @return true if message will be logged
58 */
59 boolean isDebugEnabled();
60
61 /***
62 * Log a info message.
63 *
64 * @param message the message
65 */
66 void info( String message );
67
68 /***
69 * Log a info message with an associated throwable.
70 *
71 * @param message the message
72 * @param throwable the throwable
73 */
74 void info( String message, Throwable throwable );
75
76 /***
77 * Return true if an info message will be logged.
78 *
79 * @return true if message will be logged
80 */
81 boolean isInfoEnabled();
82
83 /***
84 * Log a warn message.
85 *
86 * @param message the message
87 */
88 void warn( String message );
89
90 /***
91 * Log a warn message with an associated throwable.
92 *
93 * @param message the message
94 * @param throwable the throwable
95 */
96 void warn( String message, Throwable throwable );
97
98 /***
99 * Return true if a warn message will be logged.
100 *
101 * @return true if message will be logged
102 */
103 boolean isWarnEnabled();
104
105 /***
106 * Log a error message.
107 *
108 * @param message the message
109 */
110 void error( String message );
111
112 /***
113 * Log a error message with an associated throwable.
114 *
115 * @param message the message
116 * @param throwable the throwable
117 */
118 void error( String message, Throwable throwable );
119
120 /***
121 * Return true if a error message will be logged.
122 *
123 * @return true if message will be logged
124 */
125 boolean isErrorEnabled();
126
127 /***
128 * Get the child logger with specified name.
129 *
130 * @param name the name of child logger
131 * @return the child logger
132 */
133 Logger getChildLogger( String name );
134 }