org.teatrove.tea.parsetree
Class AssignmentStatement
java.lang.Object
org.teatrove.tea.parsetree.Node
org.teatrove.tea.parsetree.Statement
org.teatrove.tea.parsetree.AssignmentStatement
- All Implemented Interfaces:
- Serializable, Cloneable
public class AssignmentStatement
- extends Statement
AssignmentStatements can only assign values to variables, and not to
array elements. AssignmentStatements are not expressions as they are in
C or Java, and thus chaining is not allowed. i.e. a = b = c;
- Author:
- Brian S O'Neill
- See Also:
- Serialized Form
AssignmentStatement
public AssignmentStatement(SourceInfo info,
VariableRef lvalue,
Expression rvalue)
accept
public Object accept(NodeVisitor visitor)
- Description copied from class:
Node
- Every subclass of Node must override this method with the following:
return visitor.visit(this).
- Overrides:
accept in class Statement
- Parameters:
visitor - A visitor of this Node
- Returns:
- Node The Node returned by the visitor
- See Also:
NodeVisitor
clone
public Object clone()
- Description copied from class:
Node
- Returns a clone of this Node and all its children. Immutable child
objects are not necessarily cloned
- Overrides:
clone in class Node
getLValue
public VariableRef getLValue()
getRValue
public Expression getRValue()
setRValue
public void setRValue(Expression rvalue)
Copyright © 1997-2012 TeaTrove.org. All Rights Reserved.