This class represents an algebraic or logical constraint. In case the
constraint is scalar, its values can be accessed via functions like
body
and dual
.
All the AMPL suffixes for constraints (see
https://www.ampl.com/NEW/suffbuiltin.html)
are available through methods of this class with the same name (and methods
of ConstraintInstance for indexed constraints).
Note that, since this class represents both algebraic and logical
constraints, some suffixes might not be available for every entity.
An error is thrown if one of such methods is called for
a non-scalar constraint and if a method corresponding to a suffix which is
not supported by the type of the constraint is called.
An error is also thrown if any property of an entity which has been
deleted from the underlying interpreter is accessed.
To gain access to all the values in an entity (for all instances and all
suffixes for that entities), see getValues
and
the DataFrame
class.