com.extrememessaging.ResponseMaster.monitor
Class CLogger

java.lang.Object
  extended by com.extrememessaging.ResponseMaster.monitor.CMonitorBase
      extended by com.extrememessaging.ResponseMaster.monitor.CLogger
All Implemented Interfaces:
IConfigurableItem, IMonitor, RollingCount.IRollListener
Direct Known Subclasses:
CLoggerMBean

public class CLogger
extends CMonitorBase
implements RollingCount.IRollListener

This class provides methods for logging to the rest of the application


Constructor Summary
CLogger()
           
 
Method Summary
 void Initialize(java.lang.String sFileName)
          Initialize using the parameter from the config file.
 void LogError(java.lang.String sMessage)
          Log an error
 void LogError(java.lang.String sMessage, java.lang.Throwable e)
          Log an error from a Throwable
 void LogSystem(java.lang.String sMessage)
          Log a system message
 void LogTrace(java.lang.String sMessage)
          Log a tracing message If the logging level is Errors or Warnings, this doesn't do anything
 void LogTrace(java.lang.String sMessage, java.lang.Throwable e)
          Log a tracing message from a Throwable If the logging level is Errors, this doesn't do anything
 void LogWarning(java.lang.String sMessage)
          Log a warning If the logging level is Errors, this doesn't do anything
 void LogWarning(java.lang.String sMessage, java.lang.Throwable e)
          Log a warning from a Throwable If the logging level is Errors, this doesn't do anything
 void PostRoll(RollingCount source, RollingCount.RollTypeEnum rollType)
           
 void Shutdown()
          Cleanup any resources you allocated during construction or operation.
 
Methods inherited from class com.extrememessaging.ResponseMaster.monitor.CMonitorBase
CategoryDefinitionsLoaded, LoggingLevelFromString, LoggingLevelNameFromValue, MailboxEmpty, MailboxInitializationBegun, MailboxInitializationFinished, MailboxShutdownBegun, MailboxShutdownFinished, MessageCategorized, MessageProcessed, MessageSkipped, ThreadKilled
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CLogger

public CLogger()
Method Detail

Initialize

public void Initialize(java.lang.String sFileName)
                throws ResponseMasterException
Description copied from interface: IConfigurableItem
Initialize using the parameter from the config file. Frequently, the parameter will be a file name

Specified by:
Initialize in interface IConfigurableItem
Overrides:
Initialize in class CMonitorBase
Throws:
ResponseMasterException

Shutdown

public void Shutdown()
Description copied from interface: IConfigurableItem
Cleanup any resources you allocated during construction or operation. After this is called, nothing else will be called, unless Initialize is called again. Note: Shutdown may be called more than once on the same object New in build 595.

Specified by:
Shutdown in interface IConfigurableItem
Overrides:
Shutdown in class CMonitorBase

PostRoll

public void PostRoll(RollingCount source,
                     RollingCount.RollTypeEnum rollType)
Specified by:
PostRoll in interface RollingCount.IRollListener

LogError

public void LogError(java.lang.String sMessage)
Log an error

Specified by:
LogError in interface IMonitor
Overrides:
LogError in class CMonitorBase
Parameters:
sMessage - The message to log

LogError

public void LogError(java.lang.String sMessage,
                     java.lang.Throwable e)
Log an error from a Throwable

Specified by:
LogError in interface IMonitor
Overrides:
LogError in class CMonitorBase
Parameters:
sMessage - The message to log
e - The Throwable to log

LogWarning

public void LogWarning(java.lang.String sMessage)
Log a warning If the logging level is Errors, this doesn't do anything

Specified by:
LogWarning in interface IMonitor
Overrides:
LogWarning in class CMonitorBase
Parameters:
sMessage - The message to log

LogWarning

public void LogWarning(java.lang.String sMessage,
                       java.lang.Throwable e)
Log a warning from a Throwable If the logging level is Errors, this doesn't do anything

Specified by:
LogWarning in interface IMonitor
Overrides:
LogWarning in class CMonitorBase
Parameters:
sMessage - The message to log
e - The Throwable to log

LogTrace

public void LogTrace(java.lang.String sMessage)
Log a tracing message If the logging level is Errors or Warnings, this doesn't do anything

Specified by:
LogTrace in interface IMonitor
Overrides:
LogTrace in class CMonitorBase
Parameters:
sMessage - The message to log

LogTrace

public void LogTrace(java.lang.String sMessage,
                     java.lang.Throwable e)
Log a tracing message from a Throwable If the logging level is Errors, this doesn't do anything

Specified by:
LogTrace in interface IMonitor
Overrides:
LogTrace in class CMonitorBase
Parameters:
sMessage - The message to log
e - The Throwable to log

LogSystem

public void LogSystem(java.lang.String sMessage)
Log a system message

Specified by:
LogSystem in interface IMonitor
Overrides:
LogSystem in class CMonitorBase
Parameters:
sMessage - The message to log