Syslog White Paper FAQ Examples JavaDoc Classloader
Protomatter Software v1.1.7

com.protomatter.syslog
Class JDK14PerClassPolicy.PolicyGroup

java.lang.Object
  |
  +--com.protomatter.syslog.SimpleLogPolicy
        |
        +--com.protomatter.syslog.JDK14PerClassPolicy.PolicyGroup
All Implemented Interfaces:
LogPolicy
Enclosing class:
JDK14PerClassPolicy

public static class JDK14PerClassPolicy.PolicyGroup
extends SimpleLogPolicy

A policy within a policy -- this is exactly like the SimpleLogPolicy except that it also checks to see if the class issuing the log message is in some set.

See Also:
JDK14PerClassPolicy

Constructor Summary
JDK14PerClassPolicy.PolicyGroup()
          Default constructor.
 
Method Summary
 void addClass(java.lang.String classname)
          Add a classname to the set of class names we're listening to.
 void addClassPattern(java.lang.String classname)
          Add a classname to the set of class name patterns we're listening to.
 void clearClassSet()
          Clear out the set of class names we're listing to.
 void clearPatternSet()
          Clear out the set of class name patterns we're listing to.
 java.util.Iterator getClassSet()
          Get the set of class names (exact matches) we're listing to.
 java.util.Iterator getPatternSet()
          Get the set of class patterns we're listing to.
 void removeClass(java.lang.String classname)
          Remove a class name from the set of class names we're listening to.
 void removeClassPattern(java.lang.String classname)
          Remove a class name pattern from the set of class name patterns we're listening to.
 boolean shouldLog(SyslogMessage m)
          Determine if the given message should be logged.
 
Methods inherited from class com.protomatter.syslog.SimpleLogPolicy
addChannel, getChannels, getLogMask, getName, inMask, removeAllChannels, removeChannel, setChannels, setChannels, setLogMask, setLogMask, setName
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JDK14PerClassPolicy.PolicyGroup

public JDK14PerClassPolicy.PolicyGroup()
Default constructor.
Method Detail

getClassSet

public java.util.Iterator getClassSet()
Get the set of class names (exact matches) we're listing to.

clearClassSet

public void clearClassSet()
Clear out the set of class names we're listing to.

addClass

public void addClass(java.lang.String classname)
Add a classname to the set of class names we're listening to.

removeClass

public void removeClass(java.lang.String classname)
Remove a class name from the set of class names we're listening to.

getPatternSet

public java.util.Iterator getPatternSet()
Get the set of class patterns we're listing to.

clearPatternSet

public void clearPatternSet()
Clear out the set of class name patterns we're listing to.

addClassPattern

public void addClassPattern(java.lang.String classname)
Add a classname to the set of class name patterns we're listening to.

removeClassPattern

public void removeClassPattern(java.lang.String classname)
Remove a class name pattern from the set of class name patterns we're listening to.

shouldLog

public boolean shouldLog(SyslogMessage m)
Determine if the given message should be logged. The message severity and channel are first checked by our superclass, then we see if the logger class name is in our set.
Overrides:
shouldLog in class SimpleLogPolicy

Protomatter Software v1.1.7
Copyright 1998-2002 Nate Sammons

Protomatter Software v1.1.7 http://protomatter.sourceforge.net/1.1.7