org.objectweb.jonas.jetty
Class MonologLogSink

java.lang.Object
  |
  +--org.objectweb.jonas.jetty.MonologLogSink
All Implemented Interfaces:
org.mortbay.util.LifeCycle, org.mortbay.util.LogSink, java.io.Serializable

public class MonologLogSink
extends java.lang.Object
implements org.mortbay.util.LogSink, java.io.Serializable

See Also:
Serialized Form

Field Summary
protected  boolean m_bStarted
          Flag symbolizing if this m_lgLogger is started.
protected static org.objectweb.util.monolog.api.Logger m_lgLogger
          Private m_lgLogger for this class.
protected static java.util.Map s_mpLevelMap
          This map is used to map Jetty logging level to Monolog Logging level
 
Constructor Summary
MonologLogSink()
          Create new instance of m_lgLogger
 
Method Summary
 java.lang.String getOptions()
          Get the log options
 boolean isStarted()
          Check if the m_lgLogger is started
 void log(java.lang.String formattedLog)
          Log formatted message.
 void log(java.lang.String tag, java.lang.Object msg, org.mortbay.util.Frame frame, long time)
           
 void setOptions(java.lang.String options)
          Set the log options.
 void start()
          Start the m_lgLogger .
 void stop()
          Stop the m_lgLogger.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

m_lgLogger

protected static org.objectweb.util.monolog.api.Logger m_lgLogger
Private m_lgLogger for this class.

m_bStarted

protected boolean m_bStarted
Flag symbolizing if this m_lgLogger is started.

s_mpLevelMap

protected static java.util.Map s_mpLevelMap
This map is used to map Jetty logging level to Monolog Logging level
Constructor Detail

MonologLogSink

public MonologLogSink()
Create new instance of m_lgLogger
Method Detail

setOptions

public void setOptions(java.lang.String options)
Set the log options.
Specified by:
setOptions in interface org.mortbay.util.LogSink
Parameters:
options -  

getOptions

public java.lang.String getOptions()
Get the log options
Specified by:
getOptions in interface org.mortbay.util.LogSink

log

public void log(java.lang.String tag,
                java.lang.Object msg,
                org.mortbay.util.Frame frame,
                long time)
Specified by:
log in interface org.mortbay.util.LogSink

log

public void log(java.lang.String formattedLog)
Log formatted message.
Specified by:
log in interface org.mortbay.util.LogSink
Parameters:
formattedLog - - formatted message

isStarted

public boolean isStarted()
Check if the m_lgLogger is started
Specified by:
isStarted in interface org.mortbay.util.LifeCycle

start

public void start()
           throws java.lang.Exception
Start the m_lgLogger .
Specified by:
start in interface org.mortbay.util.LifeCycle
Throws:
java.lang.Exception -  

stop

public void stop()
          throws java.lang.InterruptedException
Stop the m_lgLogger.
Specified by:
stop in interface org.mortbay.util.LifeCycle
Throws:
java.lang.InterruptedException -