Class Variable

java.lang.Object
   |
   +----Symbol
           |
           +----Variable

class Variable
extends Symbol
implements Cloneable
A variable defined by they RoBOTL programmer in a new robot type.

Author:
Peter Sagerson, petersag@wpi.edu

Variable Index

 o value
The current value of the variable.

Constructor Index

 o Variable(String)
Initializes the variable to zero.
 o Variable(String, int)
Initializes the variable to n.

Method Index

 o clone()

Variables

 o value
 public int value
The current value of the variable. In a Variable object referenced by a RobotType, this is the initial value.

Constructors

 o Variable
 public Variable(String name) throws NameLengthException
Initializes the variable to zero.

 o Variable
 public Variable(String name,
                 int n) throws NameLengthException
Initializes the variable to n.

Methods

 o clone
 public Object clone()
Overrides:
clone in class Object