|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectnet.scheinerman.phoenix.interpreter.Condition
public class Condition
This class serves to encapsulate a condition in an if / else / else if block. This is used by the IfInterpreter
class to determine what code to execute in an if block. The class has a condition, associated code, and a
starting line number.
IfInterpreter}
Field Summary | |
---|---|
private java.lang.String |
code
The code to be executed if this condition is met. |
private java.lang.String |
condition
The condition to evaluate whether or not this condition should be executed. |
private int |
line
The starting line of the code to be executed. |
Constructor Summary | |
---|---|
Condition(java.lang.String condition,
java.lang.String code,
int line)
Instantiates a new condition, with the condition phrase, the associated code, and the starting line number. |
Method Summary | |
---|---|
java.lang.String |
getCode()
|
java.lang.String |
getCondition()
|
int |
getLine()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
private java.lang.String condition
private java.lang.String code
private int line
Constructor Detail |
---|
public Condition(java.lang.String condition, java.lang.String code, int line)
condition
- - The phrase of code determining whether or not this condition is true or false.code
- - The code to be executed if this condition is used.line
- - The starting line of the code to be executed.Method Detail |
---|
public java.lang.String getCondition()
public java.lang.String getCode()
public int getLine()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |