|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectunsw.cse.framescript.Term
unsw.cse.framescript.Variable
public class Variable
This class implements local variable in FrameScript.
| Field Summary | |
|---|---|
static Variable |
current_object
|
static Variable |
current_slot
|
static Variable |
newValue
|
static Variable |
oldValue
|
| Method Summary | |
|---|---|
Term |
assign(Instance currentObject,
Term arg,
StackFrame stackframe)
Assigns a value to a Term. |
boolean |
equals(Term t)
Compares two Terms for equality. |
Term |
eval(Instance currentObject,
StackFrame stackframe)
Evaluates a Term. |
Term |
mapVars(FSList vars)
Maps atoms to variables from the list of variables. |
static Variable |
newCommonVariable(Atom name)
Adds a new variable to the list of common variables. |
java.lang.String |
toString()
Turns the Term into a string. |
| Methods inherited from class unsw.cse.framescript.Term |
|---|
asString, fullMatch, indents, match |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
public static Variable current_object
public static Variable current_slot
public static Variable newValue
public static Variable oldValue
| Method Detail |
|---|
public static Variable newCommonVariable(Atom name)
name - the name of the new variable
public Term eval(Instance currentObject,
StackFrame stackframe)
throws FSException
Term
eval in class TermcurrentObject - the enclosing instance frame for the code being evaluatedstackframe - StackFrame that holds the values for any variables
FSException - if any errors occur in performing the evaluationpublic boolean equals(Term t)
Term
equals in class Termt - Term to be compared to
public Term assign(Instance currentObject,
Term arg,
StackFrame stackframe)
throws FSException
Term
assign in class TermcurrentObject - the enclosing instance frame for the code being evaluated that
is performing the assignmentarg - the unevaluated value to be assigned to the Termstackframe - StackFrame that holds the values for any variables
FSException - if assignment cannot be performedpublic Term mapVars(FSList vars)
Term
mapVars in class Termvars - a list of variables to be mapped
public java.lang.String toString()
Term
toString in class Term
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||