A relationship between two expressions (represented by Expression) that the Solver tries to hold true. In case of ambiguities, the Solver will use priorities to determine Constraint precedence. Once a Constraint is added to the Solver, this Priority cannot be changed.
Constructors
- Constraint(Expression expression, Relation relation)
-
Creates a new Constraint by specifying a single Expression. This assumes that the right hand side Expression is the constant zero. (
<expression> <relation> <0>
)
Properties
- expression → Expression
-
The Constraint Expression. The Expression on the right hand side of constraint must be zero. If the Expression on the right is not zero, it must be negated from the left hand Expression before a Constraint can be created.
read-only - priority → double
-
The Constraint Priority. The Priority can only be modified when the Constraint is being created. Once it is added to the solver, modifications to the Constraint Priority will have no effect on the how the solver evaluates the constraint.
read / write - relation → Relation
-
The Relation between a Constraint Expression and zero.
read-only - hashCode → int
-
Get a hash code for this object.
read-only, inherited - runtimeType → Type
-
A representation of the runtime type of the object.
read-only, inherited
Operators
-
operator |(
double p) → Constraint -
The operator
|
is overloaded as a convenience so that constraint priorities can be specifed along with the Constraint expression. -
operator ==(
other) → bool -
The equality operator.
inherited
Methods
-
toString(
) → String -
Returns a string representation of this object.
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a non-existent method or property is accessed.
inherited