org.apache.cactus.util.log
class LogService
java.lang.Object
|
+--org.apache.cactus.util.log.LogService
- public class LogService
- extends java.lang.Object
Logging service acting as a wrapper around the Jakarta Log4j logging
framework.
- Version:
- $Id: LogService.java,v 1.4 2002/04/14 15:56:27 vmassol Exp $
- Author:
- Vincent Massol
Constructor Summary |
LogService()
Logging service acting as a wrapper around the Jakarta Log4j logging
framework. |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
LogService
public LogService()
- Logging service acting as a wrapper around the Jakarta Log4j logging
framework.
getInstance
public static LogService getInstance()
- Returns:
- the unique singleton instance
getLog
public Log getLog(String theCategoryName)
- Parameters:
theCategoryName
- the category's name. Usually, it is the full
name of the class being logged, including the package name
- Returns:
- the
Log
instance associated with the specified
category name
init
public void init(String theFileName)
- Initialize the logging system. Need to be called once before calling
getLog()
.
- Parameters:
theFileName
- the file name (Ex: "/log_client.properties") or null
to initialize a dummy logging system, meaning that all log calls
will have no effect. This is useful for unit testing for
instance where the goal is not to verify that logs are printed.
isInitialized
public boolean isInitialized()
- Returns:
- true if the logging system has already been initialized.
Copyright © 2000-2002 Apache Software Foundation. All Rights Reserved.