All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class designer.Constraint

java.lang.Object
   |
   +----designer.Constraint

public class Constraint
extends Object
implements Step, PlanItem
This is the main constraint checking object in the design problem solver. The Constraint object encapsulates a boolean logic operation and ties it to a failure event handler (not implemented). a failure event is generated upon a false result of the logic operation(not implemented). Constraints implement the Step and PlanItem interfaces and can also be executed at the Specialist level.


Constructor Index

 o Constraint()
Default Constructor
 o Constraint(String)
Constructor with name

Method Index

 o execute()
perform the constraint check

PRE: _logicOp defined
POST: if successful return true
 o getName()
 o setLogicOp(LogicalOperation)
set the logical operation to be performed when this constraint is executed.

Constructors

 o Constraint
 public Constraint()
Default Constructor

 o Constraint
 public Constraint(String name)
Constructor with name

Methods

 o setLogicOp
 public boolean setLogicOp(LogicalOperation logOp)
set the logical operation to be performed when this constraint is executed.
PRE: logOp defined
POST: _logicOp == logOp

Parameters:
logOp - logical operation to be performed by this Constraint.
Returns:
true if successful false if failed.
 o execute
 public boolean execute()
perform the constraint check

PRE: _logicOp defined
POST: if successful return true

Returns:
true if successful false if failed.
 o getName
 public String getName()
Returns:
the String name of this object instance

All Packages  Class Hierarchy  This Package  Previous  Next  Index