All Packages Class Hierarchy This Package Previous Next Index
Class designer.IfThenElse
java.lang.Object
|
+----designer.IfThenElse
- public class IfThenElse
- extends Object
- implements Step
A step that implements an if then else construct.
the IfThenElse Object is associated with a LogicalOperation
and two Tasks, one that is perform on a true result of the logical
operation, and one that is performed on a false result
- See Also:
- LogicalOperation, Task
-
IfThenElse()
-
Default constructor
-
IfThenElse(String)
-
Constructor with name
-
execute()
- performs the logical operation then executes either the ifTask or the thenTask
PRE: _logicOp, _ifTask defined.
-
getName()
-
-
setIfTask(Task)
- set _ifTask to reference passed in.
-
setLogicOp(LogicalOperation)
- set logicOp to reference passed in.
-
setThenTask(Task)
- set _thenTask to reference passed in.
IfThenElse
public IfThenElse()
- Default constructor
IfThenElse
public IfThenElse(String name)
- Constructor with name
setLogicOp
public boolean setLogicOp(LogicalOperation logOp)
- set logicOp to reference passed in.
PRE: logOp defined
POST: logicOp == logOp
- Parameters:
- logOp - logical operation to be performed by this Constraint.
- Returns:
- true if successful false if failed.
setIfTask
public boolean setIfTask(Task ifT)
- set _ifTask to reference passed in.
PRE: ifT defined
POST:
- Parameters:
- ifT - task to assign to _ifTask.
- Returns:
- true if successful false if failed.
setThenTask
public boolean setThenTask(Task thenT)
- set _thenTask to reference passed in.
PRE: thenT defined
POST:
- Parameters:
- thenT - task to assign to _then Task.
- Returns:
- true if successful false if failed.
execute
public boolean execute()
- performs the logical operation then executes either the ifTask or the thenTask
PRE: _logicOp, _ifTask defined.
POST: if successful return true
- Returns:
- true if successful false if failed.
getName
public String getName()
- Returns:
- the String name of this object
All Packages Class Hierarchy This Package Previous Next Index