org.jcoderz.commons.logging
Class ThreadIdFilter

java.lang.Object
  extended by org.jcoderz.commons.logging.ThreadIdFilter
All Implemented Interfaces:
Filter

public final class ThreadIdFilter
extends Object
implements Filter

This filter is used for filtering log messages according to the thread id.


Constructor Summary
ThreadIdFilter(List threadIds)
          Creates a new instance of this and sets the thread ids, which will pass this filter.
 
Method Summary
 boolean isPassable(LogItem entry)
          Returns flag whether the filter lets the log file entry pass, i.e. the entry matches the filter criteria.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ThreadIdFilter

public ThreadIdFilter(List threadIds)
Creates a new instance of this and sets the thread ids, which will pass this filter. All thread ids within the supplied list must be given as Long values, otherwise they will not be detected.

Parameters:
threadIds - The list storing passable thread ids as Long values.
Method Detail

isPassable

public boolean isPassable(LogItem entry)
Returns flag whether the filter lets the log file entry pass, i.e. the entry matches the filter criteria.

Specified by:
isPassable in interface Filter
Parameters:
entry - The entry to check.
Returns:
true, if entry passes the filter; false, else.


Copyright 2007 The jCoderZ Project.