gov.sns.tools.formula.parser_source
Class FormulaGrammar

java.lang.Object
  |
  +--gov.sns.tools.formula.FormulaGrammarBase
        |
        +--gov.sns.tools.formula.parser_source.FormulaGrammar
All Implemented Interfaces:
FormulaGrammarConstants

public class FormulaGrammar
extends FormulaGrammarBase
implements FormulaGrammarConstants


Field Summary
 Token jj_nt
           
 boolean lookingAhead
           
 Token token
           
 FormulaGrammarTokenManager token_source
           
 
Fields inherited from class gov.sns.tools.formula.FormulaGrammarBase
functionTable, operatorStack, variableTable
 
Fields inherited from interface gov.sns.tools.formula.parser_source.FormulaGrammarConstants
AND, CONSTANT, DEFAULT, DIGIT, DIVIDE, EOF, EOL, FLOAT, ID, INTEGER, LETTER, MINUS, MULTIPLY, OR, PLUS, POWER, tokenImage, XOR
 
Constructor Summary
FormulaGrammar()
           
FormulaGrammar(FormulaGrammarTokenManager tm)
           
FormulaGrammar(java.io.InputStream stream)
           
FormulaGrammar(java.io.Reader stream)
           
 
Method Summary
 void disable_tracing()
           
 void element()
           
 void enable_tracing()
           
 int formula()
          parse one line of code i.e.
 void function()
           
 ParseException generateParseException()
           
 Token getNextToken()
           
 Token getToken(int index)
           
 void logical()
           
 void power()
           
 void ReInit(FormulaGrammarTokenManager tm)
           
 void ReInit(java.io.InputStream stream)
           
 void ReInit(java.io.Reader stream)
          re-initialize the parser
 void sum()
           
 void term()
           
 void unary()
           
 void variable()
           
 
Methods inherited from class gov.sns.tools.formula.FormulaGrammarBase
addBaseFunctions, addFunction, compile, getVariable, hasVariable, setVariable
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

token_source

public FormulaGrammarTokenManager token_source

token

public Token token

jj_nt

public Token jj_nt

lookingAhead

public boolean lookingAhead
Constructor Detail

FormulaGrammar

public FormulaGrammar()

FormulaGrammar

public FormulaGrammar(java.io.InputStream stream)

FormulaGrammar

public FormulaGrammar(java.io.Reader stream)

FormulaGrammar

public FormulaGrammar(FormulaGrammarTokenManager tm)
Method Detail

formula

public final int formula()
                  throws ParseException
Description copied from class: FormulaGrammarBase
parse one line of code i.e. the formula

Specified by:
formula in class FormulaGrammarBase
ParseException

logical

public final void logical()
                   throws ParseException
ParseException

sum

public final void sum()
               throws ParseException
ParseException

term

public final void term()
                throws ParseException
ParseException

power

public final void power()
                 throws ParseException
ParseException

unary

public final void unary()
                 throws ParseException
ParseException

element

public final void element()
                   throws ParseException
ParseException

variable

public final void variable()
                    throws ParseException
ParseException

function

public final void function()
                    throws ParseException
ParseException

ReInit

public void ReInit(java.io.InputStream stream)

ReInit

public void ReInit(java.io.Reader stream)
Description copied from class: FormulaGrammarBase
re-initialize the parser

Specified by:
ReInit in class FormulaGrammarBase

ReInit

public void ReInit(FormulaGrammarTokenManager tm)

getNextToken

public final Token getNextToken()

getToken

public final Token getToken(int index)

generateParseException

public final ParseException generateParseException()

enable_tracing

public final void enable_tracing()

disable_tracing

public final void disable_tracing()