FileDocCategorySizeDatePackage
ThreadLocalAppender.javaAPI DocJBoss 4.2.12844Fri Jul 13 21:02:26 BST 2007org.jboss.aspects.logging

ThreadLocalAppender

public class ThreadLocalAppender extends AppenderSkeleton
An appender that logs into a thread local array list.
author
Adrian Brock.
version
$Revision: 57186 $

Fields Summary
public static final String
LOG
private static ThreadLocal
loggingTL
Constructors Summary
Methods Summary
protected voidappend(org.apache.log4j.spi.LoggingEvent event)

      ArrayList logging = getList();
      if (logging == null)
         return;

      logging.add(event);
   
public voidclose()

   
public static java.util.ArrayListgetList()
Change the theadlocal list

param
list the new list

 

   // Attributes ----------------------------------------------------

   // Static --------------------------------------------------------

                 
      
   
      return (ArrayList) loggingTL.get();
   
public booleanrequiresLayout()

      return false;
   
public static voidsetList(java.util.ArrayList list)
Change the theadlocal list

param
list the new list

      loggingTL.set(list);