8.6.9. MDOPsdConstr

MDOPsdConstr

Represent a PSD constraint in MindOpt application.

Methods

get

Retrieve the double attribute value owned by the PSD constraint by its name

get

Retrieve the value of a String attribute owned by this PSD constraint by its name

index

Retrieve the index of this PSD constraint in this model

sameAs

Test whether this PSD constraint is the same as another

set

Set the value of the double attribute owned by the PSD variable

set

Set the value of the String attribute owned by the PSD constraint

double get(MDO.DoubleAttr attr)

Retrieve the double attribute value owned by the PSD constraint by its name.

Parameters

MDO.DoubleAttr attr – Attribute name.

Returns

Attribute value.

string get(MDO.StringAttr attr)

Retrieve the value of a String attribute owned by this PSD constraint by its name.

Parameters

MDO.StringAttr attr – Attribute name.

Returns

Attribute value.

int index()

Retrieve the index of this PSD constraint in this model.

Returns

The index of this PSD constraint.

bool sameAs(MDOPsdConstr other)

Test whether this PSD constraint is the same as another.

Parameters

MDOPsdConstr other – Another PSD constraint to be compared.

Returns

True if the two are the same.

void set(MDO.DoubleAttr attr, double value)

Set the value of the double attribute owned by the PSD variable.

Parameters
  • MDO.DoubleAttr attr – Attribute name

  • double value – The new value to be set.

void set(MDO.StringAttr attr, String value)

Set the value of the String attribute owned by the PSD constraint.

Parameters
  • MDO.StringAttr attr – Attribute name.

  • String value – The new value to be set.