com.raritantechnologies.utils.program
Class SymbolTable

java.lang.Object
  extended bycom.raritantechnologies.utils.program.SymbolTable

public class SymbolTable
extends java.lang.Object


Nested Class Summary
protected  class SymbolTable.Symbol
           
 
Field Summary
static int AND_OP
           
static int ASSIGN_OP
           
static int BOOLEAN
           
static int BOOLEAN_CONST
           
static int BOOLEAN_FUNC
           
static int BOOLEAN_VAR
           
static int CLOSE_PAREN
           
static int COMMA_OP
           
static int CONCAT_OP
           
static int DATE
           
static int DATE_CONST
           
static int DATE_FUNC
           
static int DATE_VAR
           
static int ELSE_OP
           
static int ENDIF_OP
           
static int EXIT_OP
           
static int IF_OP
           
static int INT
           
static int INT_CONST
           
static int INT_FUNC
           
static int INT_VAR
           
static int MATH_OP
           
static int NOP
           
static int NOT_OP
           
static int OPEN_PAREN
           
static int OR_OP
           
static int PRINT_OP
           
static int REL_OP
           
static int SEMICOLON_OP
           
static int STRING
           
static int STRING_CONST
           
static int STRING_FUNC
           
static int STRING_VAR
           
static int TEST_OP
           
static int THEN_OP
           
static int TYPEDEF_OP
           
static int UNKNOWN
           
 
Constructor Summary
SymbolTable()
          Constructor
 
Method Summary
 int getArity(java.lang.String nm)
          The arity of this node.
 java.lang.String getName(java.lang.String nm)
          Return the common name of this node.
 int getPrecedence(java.lang.String nm)
          The precedence of this node.
static java.lang.String getSymbol(int type)
           
 int getType(java.lang.String nm)
          Return the type of this node.
 boolean isToken(java.lang.String nm)
          Is this a Verity token?
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

UNKNOWN

public static final int UNKNOWN
See Also:
Constant Field Values

IF_OP

public static final int IF_OP
See Also:
Constant Field Values

THEN_OP

public static final int THEN_OP
See Also:
Constant Field Values

ELSE_OP

public static final int ELSE_OP
See Also:
Constant Field Values

ENDIF_OP

public static final int ENDIF_OP
See Also:
Constant Field Values

EXIT_OP

public static final int EXIT_OP
See Also:
Constant Field Values

PRINT_OP

public static final int PRINT_OP
See Also:
Constant Field Values

OR_OP

public static final int OR_OP
See Also:
Constant Field Values

AND_OP

public static final int AND_OP
See Also:
Constant Field Values

REL_OP

public static final int REL_OP
See Also:
Constant Field Values

TYPEDEF_OP

public static final int TYPEDEF_OP
See Also:
Constant Field Values

ASSIGN_OP

public static final int ASSIGN_OP
See Also:
Constant Field Values

SEMICOLON_OP

public static final int SEMICOLON_OP
See Also:
Constant Field Values

COMMA_OP

public static final int COMMA_OP
See Also:
Constant Field Values

STRING_FUNC

public static final int STRING_FUNC
See Also:
Constant Field Values

INT_FUNC

public static final int INT_FUNC
See Also:
Constant Field Values

BOOLEAN_FUNC

public static final int BOOLEAN_FUNC
See Also:
Constant Field Values

STRING

public static final int STRING
See Also:
Constant Field Values

INT

public static final int INT
See Also:
Constant Field Values

BOOLEAN

public static final int BOOLEAN
See Also:
Constant Field Values

STRING_VAR

public static final int STRING_VAR
See Also:
Constant Field Values

INT_VAR

public static final int INT_VAR
See Also:
Constant Field Values

BOOLEAN_VAR

public static final int BOOLEAN_VAR
See Also:
Constant Field Values

STRING_CONST

public static final int STRING_CONST
See Also:
Constant Field Values

INT_CONST

public static final int INT_CONST
See Also:
Constant Field Values

BOOLEAN_CONST

public static final int BOOLEAN_CONST
See Also:
Constant Field Values

NOT_OP

public static final int NOT_OP
See Also:
Constant Field Values

TEST_OP

public static final int TEST_OP
See Also:
Constant Field Values

NOP

public static final int NOP
See Also:
Constant Field Values

OPEN_PAREN

public static final int OPEN_PAREN
See Also:
Constant Field Values

CLOSE_PAREN

public static final int CLOSE_PAREN
See Also:
Constant Field Values

DATE_FUNC

public static final int DATE_FUNC
See Also:
Constant Field Values

DATE

public static final int DATE
See Also:
Constant Field Values

DATE_VAR

public static final int DATE_VAR
See Also:
Constant Field Values

DATE_CONST

public static final int DATE_CONST
See Also:
Constant Field Values

MATH_OP

public static final int MATH_OP
See Also:
Constant Field Values

CONCAT_OP

public static final int CONCAT_OP
See Also:
Constant Field Values
Constructor Detail

SymbolTable

public SymbolTable()
Constructor

Method Detail

getName

public java.lang.String getName(java.lang.String nm)
Return the common name of this node.


getType

public int getType(java.lang.String nm)
Return the type of this node. BOOL_OP, MODIFIER, etc.


getArity

public int getArity(java.lang.String nm)
The arity of this node.


getPrecedence

public int getPrecedence(java.lang.String nm)
The precedence of this node.


isToken

public boolean isToken(java.lang.String nm)
Is this a Verity token?


getSymbol

public static java.lang.String getSymbol(int type)