Logback API
Version 0.9.8

ch.qos.logback.core.boolex
Class JaninoEventEvaluatorBase

java.lang.Object
  extended by ch.qos.logback.core.spi.ContextAwareBase
      extended by ch.qos.logback.core.boolex.JaninoEventEvaluatorBase
All Implemented Interfaces:
EventEvaluator, ContextAware, LifeCycle
Direct Known Subclasses:
JaninoEventEvaluator, JaninoEventEvaluator

public abstract class JaninoEventEvaluatorBase
extends ContextAwareBase
implements EventEvaluator, LifeCycle


Field Summary
static int ERROR_THRESHOLD
           
protected  List<Matcher> matcherList
           
protected  boolean start
           
 
Fields inherited from class ch.qos.logback.core.spi.ContextAwareBase
context
 
Constructor Summary
JaninoEventEvaluatorBase()
           
 
Method Summary
 void addMatcher(Matcher matcher)
           
 boolean evaluate(Object event)
          Evaluates whether the event passed as parameter matches this evaluator's matching criteria.
protected abstract  String getDecoratedExpression()
           
 String getExpression()
           
 List getMatcherList()
           
 String getName()
          Evaluators are named entities.
protected abstract  String[] getParameterNames()
           
protected abstract  Class[] getParameterTypes()
           
protected abstract  Object[] getParameterValues(Object event)
           
 boolean isStarted()
           
 void setExpression(String expression)
           
 void setName(String name)
          Evaluators are named entities.
 void start()
           
 void stop()
           
 
Methods inherited from class ch.qos.logback.core.spi.ContextAwareBase
addError, addError, addInfo, addInfo, addStatus, addWarn, addWarn, getContext, getStatusManager, setContext
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface ch.qos.logback.core.spi.ContextAware
addError, addError, addInfo, addInfo, addStatus, addWarn, addWarn, getContext, setContext
 

Field Detail

ERROR_THRESHOLD

public static final int ERROR_THRESHOLD
See Also:
Constant Field Values

start

protected boolean start

matcherList

protected List<Matcher> matcherList
Constructor Detail

JaninoEventEvaluatorBase

public JaninoEventEvaluatorBase()
Method Detail

getDecoratedExpression

protected abstract String getDecoratedExpression()

getParameterNames

protected abstract String[] getParameterNames()

getParameterTypes

protected abstract Class[] getParameterTypes()

getParameterValues

protected abstract Object[] getParameterValues(Object event)

isStarted

public boolean isStarted()
Specified by:
isStarted in interface LifeCycle

stop

public void stop()
Specified by:
stop in interface LifeCycle

start

public void start()
Specified by:
start in interface LifeCycle

evaluate

public boolean evaluate(Object event)
                 throws EvaluationException
Description copied from interface: EventEvaluator
Evaluates whether the event passed as parameter matches this evaluator's matching criteria.

The Evaluator instance is free to evaluate the event as it pleases. In particular, the evaluation results may depend on previous events.

Specified by:
evaluate in interface EventEvaluator
Parameters:
event - The event to evaluate
Returns:
true if there is a match, false otherwise.
Throws:
EvaluationException - Thrown during evaluation

getName

public String getName()
Description copied from interface: EventEvaluator
Evaluators are named entities.

Specified by:
getName in interface EventEvaluator
Returns:
The name of this evaluator.

setName

public void setName(String name)
Description copied from interface: EventEvaluator
Evaluators are named entities.

Specified by:
setName in interface EventEvaluator

getExpression

public String getExpression()

setExpression

public void setExpression(String expression)

addMatcher

public void addMatcher(Matcher matcher)

getMatcherList

public List getMatcherList()

Logback API
Version 0.9.8

Copyright © 2005-2008 QOS.ch. All Rights Reserved.