|
Venice 0.7beta | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.mov.parser.Variable
public class Variable
A representation of a variable in the Gondola language.
| Field Summary | |
|---|---|
static boolean |
CONSTANT
Indicates that the variable is constant and the value cannot be changed. |
static boolean |
VARIABLE
Indicates that the variable can be changed. |
| Constructor Summary | |
|---|---|
Variable(java.lang.String name,
int type,
boolean isConstant,
double value)
Create a new variable. |
|
| Method Summary | |
|---|---|
java.lang.String |
getName()
Return the name of the variable. |
int |
getType()
Return the type of the variable. |
double |
getValue()
Return the value of the variable. |
boolean |
isConstant()
Return whether the variable is a constant. |
void |
setValue(double value)
Set the value of the variable. |
void |
setValue(int value)
Set the value of the variable. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final boolean CONSTANT
public static final boolean VARIABLE
| Constructor Detail |
|---|
public Variable(java.lang.String name,
int type,
boolean isConstant,
double value)
name - the name of the variable.type - the type of the variable, one of Expression.BOOLEAN_TYPE,
Expression.FLOAT_TYPE or Expression.INTEGER_TYPE.isConstant - whether the variable is constant. Either @{link CONSTANT} or
VARIABLE.value - the initial value of the variable.| Method Detail |
|---|
public java.lang.String getName()
public int getType()
public boolean isConstant()
TRUE iff the variable is a constant.public double getValue()
public void setValue(double value)
value - the new value.public void setValue(int value)
value - the new value.
|
Venice 0.7beta | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||