org.apache.activemq.transport.logwriters
Class DefaultLogWriter

java.lang.Object
  extended by org.apache.activemq.transport.logwriters.DefaultLogWriter
All Implemented Interfaces:
LogWriter

public class DefaultLogWriter
extends Object
implements LogWriter

Implementation of LogWriter interface to keep ActiveMQ's old logging format.

Author:
David Martin Clavo david(dot)martin(dot)clavo(at)gmail.com

Constructor Summary
DefaultLogWriter()
           
 
Method Summary
 void initialMessage(Logger log)
          Writes a header message to the log.
 void logAsyncRequest(Logger log, Object command)
          Writes a message to a log when an asynchronous equest command is sent.
 void logOneWay(Logger log, Object command)
          Writes a message to a log when message is sent.
 void logReceivedCommand(Logger log, Object command)
          Writes a message to a log when message is received.
 void logReceivedException(Logger log, IOException error)
          Writes a message to a log when an exception is received.
 void logRequest(Logger log, Object command)
          Writes a message to a log when a request command is sent.
 void logResponse(Logger log, Object response)
          Writes a message to a log when a response command is received.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DefaultLogWriter

public DefaultLogWriter()
Method Detail

initialMessage

public void initialMessage(Logger log)
Description copied from interface: LogWriter
Writes a header message to the log.

Specified by:
initialMessage in interface LogWriter
Parameters:
log - The log to be written to.

logRequest

public void logRequest(Logger log,
                       Object command)
Description copied from interface: LogWriter
Writes a message to a log when a request command is sent.

Specified by:
logRequest in interface LogWriter
Parameters:
log - The log to be written to.
command - The command to be logged.

logResponse

public void logResponse(Logger log,
                        Object response)
Description copied from interface: LogWriter
Writes a message to a log when a response command is received.

Specified by:
logResponse in interface LogWriter
Parameters:
log - The log to be written to.

logAsyncRequest

public void logAsyncRequest(Logger log,
                            Object command)
Description copied from interface: LogWriter
Writes a message to a log when an asynchronous equest command is sent.

Specified by:
logAsyncRequest in interface LogWriter
Parameters:
log - The log to be written to.
command - The command to be logged.

logOneWay

public void logOneWay(Logger log,
                      Object command)
Description copied from interface: LogWriter
Writes a message to a log when message is sent.

Specified by:
logOneWay in interface LogWriter
Parameters:
log - The log to be written to.
command - The command to be logged.

logReceivedCommand

public void logReceivedCommand(Logger log,
                               Object command)
Description copied from interface: LogWriter
Writes a message to a log when message is received.

Specified by:
logReceivedCommand in interface LogWriter
Parameters:
log - The log to be written to.
command - The command to be logged.

logReceivedException

public void logReceivedException(Logger log,
                                 IOException error)
Description copied from interface: LogWriter
Writes a message to a log when an exception is received.

Specified by:
logReceivedException in interface LogWriter
Parameters:
log - The log to be written to.


Copyright © 2005-2012 The Apache Software Foundation. All Rights Reserved.