ObjectiveInstance

public class ObjectiveInstance extends Instance<Objective>

Represents an objective instance.

All AMPL suffixes for an objective are available through methods with the same name in this class. See http://www.ampl.com/NEW/suffbuiltin.html for a list of the available suffixes.

All the accessors in this class throw a IllegalStateException if the instance has been deleted in the underlying AMPL interpreter.

Methods

public String astatus()

Return the AMPL status

public void drop()

Drop this objective instance

public int exitcode()

Exit code returned by solver after most recent solve with this objective

public String message()

Result message returned by solver after most recent solve with this objective

public void restore()

Restore this objective instance (if it had been dropped, no effect otherwise)

public String result()

Result string returned by solver after most recent solve with this objective

public String sstatus()

Return the solver status

public String toString()

Returns a string representation of this instance. Returns the equivalent to the AMPL statement:

expand instanceName;
public double value()

Get the value of the objective instance