uk.co.agena.minerva.util.nptgenerator
Class ExpressionParser

java.lang.Object
  extended by org.nfunk.jep.JEP
      extended by uk.co.agena.minerva.util.nptgenerator.ExpressionParser

public class ExpressionParser
extends org.nfunk.jep.JEP

This is a Minerva-specific parser that encapsulates various data and behaviour common throughout the NPT generation process.


Field Summary
 
Fields inherited from class org.nfunk.jep.JEP
allowAssignment, allowUndeclared, errorList, ev, funTab, implicitMul, numberFactory, opSet, parser, symTab
 
Constructor Summary
ExpressionParser()
          Creates a basic Expression parser.
 
Method Summary
 void addDataSetVars(DataSet dataSet)
          Adds list of strings as variables to parser with string or double value.
 void addStringVars(java.util.List variables)
          Adds list of strings as variables to parser with value of 0.0.
 void addVariableVars(java.util.List variables)
          Adds list of strings as variables to parser with value set.
 void checkForErrors(java.lang.String nodeName)
           
static ExpressionParser getInstance()
           
 void removeDataSetVars(DataSet dataSet)
          Removes from the parser variables with names matching those in the supplied List.
 void removeStringVars(java.util.List variables)
          Removes from the parser variables with names matching those in the supplied List.
 void removeVariableVars(java.util.List variables)
          Removes from the parser variables with names matching those in the supplied List.
 
Methods inherited from class org.nfunk.jep.JEP
addComplex, addConstant, addFunction, addStandardConstants, addStandardFunctions, addVariable, addVariable, addVariable, evaluate, getAllowAssignment, getAllowUndeclared, getComplexValue, getErrorInfo, getFunctionTable, getImplicitMul, getNumberFactory, getOperatorSet, getParser, getSymbolTable, getTopNode, getTraverse, getValue, getValueAsObject, getVar, getVarValue, hasError, initFunTab, initSymTab, parse, parseExpression, removeFunction, removeVariable, setAllowAssignment, setAllowUndeclared, setImplicitMul, setTraverse, setVarValue
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ExpressionParser

public ExpressionParser()
Creates a basic Expression parser.

Method Detail

getInstance

public static ExpressionParser getInstance()

addDataSetVars

public void addDataSetVars(DataSet dataSet)
Adds list of strings as variables to parser with string or double value.

Parameters:
variables -

removeDataSetVars

public void removeDataSetVars(DataSet dataSet)
Removes from the parser variables with names matching those in the supplied List.

Parameters:
variables -

addVariableVars

public void addVariableVars(java.util.List variables)
Adds list of strings as variables to parser with value set.

Parameters:
variables -

removeVariableVars

public void removeVariableVars(java.util.List variables)
Removes from the parser variables with names matching those in the supplied List.

Parameters:
variables -

addStringVars

public void addStringVars(java.util.List variables)
Adds list of strings as variables to parser with value of 0.0.

Parameters:
variables -

removeStringVars

public void removeStringVars(java.util.List variables)
Removes from the parser variables with names matching those in the supplied List.

Parameters:
variables -

checkForErrors

public void checkForErrors(java.lang.String nodeName)
                    throws NPTGeneratorException
Throws:
NPTGeneratorException


Copyright © 2006 Agena Ltd. All Rights Reserved.