anl.aida.query
Class ASTCount

java.lang.Object
  extended by anl.aida.query.SimpleNode
      extended by anl.aida.query.ASTCount
All Implemented Interfaces:
Node

public class ASTCount
extends SimpleNode


Field Summary
 
Fields inherited from class anl.aida.query.SimpleNode
children, id, parent, parser
 
Constructor Summary
ASTCount(int id)
           
ASTCount(Parser p, int id)
           
 
Method Summary
 double evaluate(Frame source)
          Evaluates this Node and returns a double as a result.
private  double evaluateMultTerm(Frame source)
           
private  double evaluateSingleTerm(Frame source)
           
 java.lang.String getCacheKey()
           
 
Methods inherited from class anl.aida.query.SimpleNode
dump, jjtAddChild, jjtClose, jjtGetChild, jjtGetNumChildren, jjtGetParent, jjtOpen, jjtSetParent, toString, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ASTCount

public ASTCount(int id)

ASTCount

public ASTCount(Parser p,
                int id)
Method Detail

getCacheKey

public java.lang.String getCacheKey()
Specified by:
getCacheKey in interface Node
Overrides:
getCacheKey in class SimpleNode

evaluateSingleTerm

private double evaluateSingleTerm(Frame source)

evaluateMultTerm

private double evaluateMultTerm(Frame source)

evaluate

public double evaluate(Frame source)
Description copied from class: SimpleNode
Evaluates this Node and returns a double as a result. Default implementation throws an UnsupportedOperationException.

Specified by:
evaluate in interface Node
Overrides:
evaluate in class SimpleNode
Parameters:
source - the source of any data needed during evaluation
Returns:
the result of the evaulation.