org.ojalgo.optimisation
Class ConstraintsBasedModel
java.lang.Object
org.ojalgo.optimisation.ConstraintsBasedModel
- All Implemented Interfaces:
- OptimisationModel
public abstract class ConstraintsBasedModel
- extends Object
ConstraintsBasedModel
public ConstraintsBasedModel(Constraint[] someConstraints)
ConstraintsBasedModel
public ConstraintsBasedModel(Set<? extends Constraint> someConstraints)
getConstraints
public Constraint[] getConstraints()
isMaximisation
public final boolean isMaximisation()
- Specified by:
isMaximisation in interface OptimisationModel
- Returns:
- true if this model is a maximisation problem, and false
if it's a minimisation problem
isMinimisation
public final boolean isMinimisation()
- Specified by:
isMinimisation in interface OptimisationModel
- Returns:
- true if this model is a minimisation problem, and false
if it's a maximisation problem
setMaximisation
public final void setMaximisation(boolean aFlag)
- Description copied from interface:
OptimisationModel
- Marks the model to be a maximisation problem, or not.
Minimisation is the default.
- Specified by:
setMaximisation in interface OptimisationModel
setMinimisation
public final void setMinimisation(boolean aFlag)
- Description copied from interface:
OptimisationModel
- Marks the model to be a minimisation problem, or not.
Minimisation is the default.
- Specified by:
setMinimisation in interface OptimisationModel
getValue
public BigDecimal getValue()
- Returns:
- The current objective function value