Package org.exoplatform.services.log
Class LogConfigurationInitializer
- java.lang.Object
-
- org.exoplatform.services.log.LogConfigurationInitializer
-
- All Implemented Interfaces:
Startable
public class LogConfigurationInitializer extends Object implements Startable
Created by The eXo Platform SAS.
The component for commons based logging configuration initialization. There are 3 optional initialization parameters: logger - a logger class implemented org.exoplatform.services.log.Log configurator - a log system configurator implementation of LogConfigurator parameters - list of parameters for the configurator- Version:
- $Id: LogConfigurationInitializer.java 5332 2006-04-29 18:32:44Z geaz $
- Author:
- Gennady Azarenkov
-
-
Constructor Summary
Constructors Constructor Description LogConfigurationInitializer(String logger, String configurator, Properties properties)Simple constructor, not for use in containerLogConfigurationInitializer(InitParams params)Constructor for in-container using
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description StringgetConfiguratorClass()StringgetLoggerClass()MapgetProperties()voidremoveProperty(String name)Removes propertyvoidsetProperty(String name, String value)Updates or adds propertyvoidstart()Start this component.voidstop()Stop this component.
-
-
-
Constructor Detail
-
LogConfigurationInitializer
public LogConfigurationInitializer(InitParams params) throws Exception
Constructor for in-container using- Parameters:
params- - initialization parameters, optionally included logger, configurator and properties- Throws:
Exception
-
LogConfigurationInitializer
public LogConfigurationInitializer(String logger, String configurator, Properties properties) throws Exception
Simple constructor, not for use in container- Parameters:
logger-configurator-properties-- Throws:
Exception
-
-
Method Detail
-
getLoggerClass
public String getLoggerClass()
- Returns:
- logger class name
-
getConfiguratorClass
public String getConfiguratorClass()
- Returns:
- configurator class name
-
getProperties
public Map getProperties()
- Returns:
- current Log properties (name-value pairs)
-
setProperty
public void setProperty(String name, String value) throws Exception
Updates or adds property- Parameters:
name-value-- Throws:
Exception
-
removeProperty
public void removeProperty(String name) throws Exception
Removes property- Parameters:
name-- Throws:
Exception
-
start
public void start()
Description copied from interface:StartableStart this component. Called initially at the begin of the lifecycle. It can be called again after a stop.
-
stop
public void stop()
Description copied from interface:StartableStop this component. Called near the end of the lifecycle. It can be called again after a further start. ImplementDisposableif you need a single call at the definite end of the lifecycle.
-
-