Source Code Cross Referenced for Log.java in  » Development » SLF4J » org » apache » commons » logging » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » Development » SLF4J » org.apache.commons.logging 
Source Cross Referenced  Class Diagram Java Document (Java Doc) 


001:        /*
002:         * Copyright 2001-2004 The Apache Software Foundation.
003:         * 
004:         * Licensed under the Apache License, Version 2.0 (the "License");
005:         * you may not use this file except in compliance with the License.
006:         * You may obtain a copy of the License at
007:         * 
008:         *      http://www.apache.org/licenses/LICENSE-2.0
009:         * 
010:         * Unless required by applicable law or agreed to in writing, software
011:         * distributed under the License is distributed on an "AS IS" BASIS,
012:         * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
013:         * See the License for the specific language governing permissions and
014:         * limitations under the License.
015:         */
016:
017:        package org.apache.commons.logging;
018:
019:        /**
020:         * <p>A simple logging interface abstracting logging APIs.  In order to be
021:         * instantiated successfully by {@link LogFactory}, classes that implement
022:         * this interface must have a constructor that takes a single String
023:         * parameter representing the "name" of this Log.</p>
024:         *
025:         * <p> The six logging levels used by <code>Log</code> are (in order):
026:         * <ol>
027:         * <li>trace (the least serious)</li>
028:         * <li>debug</li>
029:         * <li>info</li>
030:         * <li>warn</li>
031:         * <li>error</li>
032:         * <li>fatal (the most serious)</li>
033:         * </ol>
034:         * The mapping of these log levels to the concepts used by the underlying
035:         * logging system is implementation dependent.
036:         * The implemention should ensure, though, that this ordering behaves
037:         * as expected.</p>
038:         *
039:         * <p>Performance is often a logging concern.
040:         * By examining the appropriate property,
041:         * a component can avoid expensive operations (producing information
042:         * to be logged).</p>
043:         *
044:         * <p> For example,
045:         * <code><pre>
046:         *    if (log.isDebugEnabled()) {
047:         *        ... do something expensive ...
048:         *        log.debug(theResult);
049:         *    }
050:         * </pre></code>
051:         * </p>
052:         *
053:         * <p>Configuration of the underlying logging system will generally be done
054:         * external to the Logging APIs, through whatever mechanism is supported by
055:         * that system.</p>
056:         *
057:         * <p style="color: #E40; font-weight: bold;">Please note that this interface is identical to that found in JCL 1.0.4.</p>
058:         * 
059:         * @author <a href="mailto:sanders@apache.org">Scott Sanders</a>
060:         * @author Rod Waldhoff
061:         * @version $Id: Log.java,v 1.19 2004/06/06 21:16:04 rdonkin Exp $
062:         */
063:        public interface Log {
064:
065:            // ----------------------------------------------------- Logging Properties
066:
067:            /**
068:             * <p> Is debug logging currently enabled? </p>
069:             *
070:             * <p> Call this method to prevent having to perform expensive operations
071:             * (for example, <code>String</code> concatenation)
072:             * when the log level is more than debug. </p>
073:             */
074:            public boolean isDebugEnabled();
075:
076:            /**
077:             * <p> Is error logging currently enabled? </p>
078:             *
079:             * <p> Call this method to prevent having to perform expensive operations
080:             * (for example, <code>String</code> concatenation)
081:             * when the log level is more than error. </p>
082:             */
083:            public boolean isErrorEnabled();
084:
085:            /**
086:             * <p> Is fatal logging currently enabled? </p>
087:             *
088:             * <p> Call this method to prevent having to perform expensive operations
089:             * (for example, <code>String</code> concatenation)
090:             * when the log level is more than fatal. </p>
091:             */
092:            public boolean isFatalEnabled();
093:
094:            /**
095:             * <p> Is info logging currently enabled? </p>
096:             *
097:             * <p> Call this method to prevent having to perform expensive operations
098:             * (for example, <code>String</code> concatenation)
099:             * when the log level is more than info. </p>
100:             */
101:            public boolean isInfoEnabled();
102:
103:            /**
104:             * <p> Is trace logging currently enabled? </p>
105:             *
106:             * <p> Call this method to prevent having to perform expensive operations
107:             * (for example, <code>String</code> concatenation)
108:             * when the log level is more than trace. </p>
109:             */
110:            public boolean isTraceEnabled();
111:
112:            /**
113:             * <p> Is warn logging currently enabled? </p>
114:             *
115:             * <p> Call this method to prevent having to perform expensive operations
116:             * (for example, <code>String</code> concatenation)
117:             * when the log level is more than warn. </p>
118:             */
119:            public boolean isWarnEnabled();
120:
121:            // -------------------------------------------------------- Logging Methods
122:
123:            /**
124:             * <p> Log a message with trace log level. </p>
125:             *
126:             * @param message log this message
127:             */
128:            public void trace(Object message);
129:
130:            /**
131:             * <p> Log an error with trace log level. </p>
132:             *
133:             * @param message log this message
134:             * @param t log this cause
135:             */
136:            public void trace(Object message, Throwable t);
137:
138:            /**
139:             * <p> Log a message with debug log level. </p>
140:             *
141:             * @param message log this message
142:             */
143:            public void debug(Object message);
144:
145:            /**
146:             * <p> Log an error with debug log level. </p>
147:             *
148:             * @param message log this message
149:             * @param t log this cause
150:             */
151:            public void debug(Object message, Throwable t);
152:
153:            /**
154:             * <p> Log a message with info log level. </p>
155:             *
156:             * @param message log this message
157:             */
158:            public void info(Object message);
159:
160:            /**
161:             * <p> Log an error with info log level. </p>
162:             *
163:             * @param message log this message
164:             * @param t log this cause
165:             */
166:            public void info(Object message, Throwable t);
167:
168:            /**
169:             * <p> Log a message with warn log level. </p>
170:             *
171:             * @param message log this message
172:             */
173:            public void warn(Object message);
174:
175:            /**
176:             * <p> Log an error with warn log level. </p>
177:             *
178:             * @param message log this message
179:             * @param t log this cause
180:             */
181:            public void warn(Object message, Throwable t);
182:
183:            /**
184:             * <p> Log a message with error log level. </p>
185:             *
186:             * @param message log this message
187:             */
188:            public void error(Object message);
189:
190:            /**
191:             * <p> Log an error with error log level. </p>
192:             *
193:             * @param message log this message
194:             * @param t log this cause
195:             */
196:            public void error(Object message, Throwable t);
197:
198:            /**
199:             * <p> Log a message with fatal log level. </p>
200:             *
201:             * @param message log this message
202:             */
203:            public void fatal(Object message);
204:
205:            /**
206:             * <p> Log an error with fatal log level. </p>
207:             *
208:             * @param message log this message
209:             * @param t log this cause
210:             */
211:            public void fatal(Object message, Throwable t);
212:
213:        }
www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.