com.voytechs.jnetstream.npl
Class ForStatement

java.lang.Object
  extended by com.voytechs.jnetstream.npl.Node
      extended by com.voytechs.jnetstream.npl.StatementNode
          extended by com.voytechs.jnetstream.npl.ForStatement
All Implemented Interfaces:
Visitable

public class ForStatement
extends StatementNode
implements Visitable


Field Summary
protected  BooleanNode condition
           
protected  Node forCode
           
protected  Node initCode
           
 
Fields inherited from class com.voytechs.jnetstream.npl.StatementNode
code, modifiers, perm, statement, sym, token, type, typePrimitive, value
 
Fields inherited from class com.voytechs.jnetstream.npl.Node
parent
 
Constructor Summary
ForStatement()
           
 
Method Summary
 BooleanNode getCondition()
           
 Node getForCode()
           
 Node getInitCode()
           
static void main(java.lang.String[] args)
          Test function for ForStatement
 Node parse(ExpTokenizer tokens)
           
protected  void parseCondition(ExpTokenizer tokens)
           
protected  void parseForCode(ExpTokenizer tokens)
           
protected  void parseInitCode(ExpTokenizer tokens)
           
 boolean visit(Visitor visitor, java.lang.Object user1, java.lang.Object user2)
           
 
Methods inherited from class com.voytechs.jnetstream.npl.StatementNode
acceptCode, acceptLValue, acceptModifier, acceptStatement, canOptimize, getCode, getLineNumber, getName, getPermTable, getStatement, getSymTable, getType, getTypePrimitive, optimize, parseCode, parseLValue, parseModifiers, parsePostModifiers, setSymTable, setTypePrimitive, toString
 
Methods inherited from class com.voytechs.jnetstream.npl.Node
getParent, getToken, setParent, setToken
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

condition

protected BooleanNode condition

forCode

protected Node forCode

initCode

protected Node initCode
Constructor Detail

ForStatement

public ForStatement()
Parameters:
-
Throws:
Method Detail

parse

public Node parse(ExpTokenizer tokens)
           throws SyntaxError
Overrides:
parse in class StatementNode
Throws:
SyntaxError

visit

public boolean visit(Visitor visitor,
                     java.lang.Object user1,
                     java.lang.Object user2)
              throws NodeException
Specified by:
visit in interface Visitable
Throws:
NodeException

parseCondition

protected void parseCondition(ExpTokenizer tokens)
                       throws SyntaxError
Throws:
SyntaxError

parseInitCode

protected void parseInitCode(ExpTokenizer tokens)
                      throws SyntaxError
Throws:
SyntaxError

getInitCode

public Node getInitCode()

parseForCode

protected void parseForCode(ExpTokenizer tokens)
                     throws SyntaxError
Throws:
SyntaxError

getForCode

public Node getForCode()

getCondition

public BooleanNode getCondition()

main

public static void main(java.lang.String[] args)
Test function for ForStatement

Parameters:
args - command line arguments