public class InequalityRule extends AbstractRule
Modifier and Type | Method and Description |
---|---|
boolean |
evaluate(org.apache.log4j.spi.LoggingEvent event,
Map matches)
Returns true if this implementation of the rule accepts the LoggingEvent,
or false if not.
|
static Rule |
getRule(String inequalitySymbol,
Stack stack)
Create new instance from top two elements on stack.
|
static Rule |
getRule(String inequalitySymbol,
String field,
String value)
Create new instance from top two elements on stack.
|
addPropertyChangeListener, firePropertyChange, firePropertyChange, removePropertyChangeListener
public static Rule getRule(String inequalitySymbol, Stack stack)
inequalitySymbol
- inequality symbol.stack
- stack.public static Rule getRule(String inequalitySymbol, String field, String value)
inequalitySymbol
- inequality symbol.field
- field.value
- comparison value.public boolean evaluate(org.apache.log4j.spi.LoggingEvent event, Map matches)
What True/False means can be client-specific.
event
- LoggingEvent this instance will evaluatematches
- a Map of event field keys to Sets of matching strings (may be null) which will be
updated during execution of this method to include field and string matches based on the rule
evaluation resultsCopyright © 2013 The Apache Software Foundation. Licensed under the Apache License, Version 2.0
Apache Extras for Apache log4j, Apache log4j and Apache are trademarks of the Apache Software Foundation.