org.jboss.modules.log
Class StreamModuleLogger

java.lang.Object
  extended by org.jboss.modules.log.StreamModuleLogger
All Implemented Interfaces:
ModuleLogger

public final class StreamModuleLogger
extends Object
implements ModuleLogger

A ModuleLogger implementation that logs all output (including trace) to an output or print stream.

Author:
thomas.diesler@jboss.com, David M. Lloyd

Constructor Summary
StreamModuleLogger(OutputStream stream)
          Construct a new instance.
StreamModuleLogger(PrintStream stream)
          Construct a new instance.
 
Method Summary
 void classDefined(String name, Module module)
           
 void classDefineFailed(Throwable throwable, String className, Module module)
          
 void greeting()
          
 void moduleDefined(ModuleIdentifier identifier, ModuleLoader moduleLoader)
          
 void providerUnloadable(String name, ClassLoader loader)
           
 void trace(String message)
          
 void trace(String format, Object... args)
          
 void trace(String format, Object arg1)
          
 void trace(String format, Object arg1, Object arg2)
          
 void trace(String format, Object arg1, Object arg2, Object arg3)
          
 void trace(Throwable t, String message)
          
 void trace(Throwable t, String format, Object... args)
          
 void trace(Throwable t, String format, Object arg1)
          
 void trace(Throwable t, String format, Object arg1, Object arg2)
          
 void trace(Throwable t, String format, Object arg1, Object arg2, Object arg3)
          
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

StreamModuleLogger

public StreamModuleLogger(PrintStream stream)
Construct a new instance.

Parameters:
stream - the print stream to write to

StreamModuleLogger

public StreamModuleLogger(OutputStream stream)
Construct a new instance.

Parameters:
stream - the output stream to write to
Method Detail

trace

public void trace(String message)

Specified by:
trace in interface ModuleLogger

trace

public void trace(String format,
                  Object arg1)

Specified by:
trace in interface ModuleLogger

trace

public void trace(String format,
                  Object arg1,
                  Object arg2)

Specified by:
trace in interface ModuleLogger

trace

public void trace(String format,
                  Object arg1,
                  Object arg2,
                  Object arg3)

Specified by:
trace in interface ModuleLogger

trace

public void trace(String format,
                  Object... args)

Specified by:
trace in interface ModuleLogger

trace

public void trace(Throwable t,
                  String message)

Specified by:
trace in interface ModuleLogger

trace

public void trace(Throwable t,
                  String format,
                  Object arg1)

Specified by:
trace in interface ModuleLogger

trace

public void trace(Throwable t,
                  String format,
                  Object arg1,
                  Object arg2)

Specified by:
trace in interface ModuleLogger

trace

public void trace(Throwable t,
                  String format,
                  Object arg1,
                  Object arg2,
                  Object arg3)

Specified by:
trace in interface ModuleLogger

trace

public void trace(Throwable t,
                  String format,
                  Object... args)

Specified by:
trace in interface ModuleLogger

greeting

public void greeting()

Specified by:
greeting in interface ModuleLogger

moduleDefined

public void moduleDefined(ModuleIdentifier identifier,
                          ModuleLoader moduleLoader)

Specified by:
moduleDefined in interface ModuleLogger

classDefineFailed

public void classDefineFailed(Throwable throwable,
                              String className,
                              Module module)

Specified by:
classDefineFailed in interface ModuleLogger

classDefined

public void classDefined(String name,
                         Module module)
Specified by:
classDefined in interface ModuleLogger

providerUnloadable

public void providerUnloadable(String name,
                               ClassLoader loader)
Specified by:
providerUnloadable in interface ModuleLogger


Copyright © 2011. All Rights Reserved.