org.ojalgo.optimisation
Class ConstraintsBasedModel

java.lang.Object
  extended by org.ojalgo.optimisation.ConstraintsBasedModel
All Implemented Interfaces:
OptimisationModel

public abstract class ConstraintsBasedModel
extends Object


Constructor Summary
ConstraintsBasedModel(Constraint[] someConstraints)
           
ConstraintsBasedModel(Set<? extends Constraint> someConstraints)
           
 
Method Summary
 Constraint[] getConstraints()
           
 BigDecimal getValue()
           
 boolean isMaximisation()
           
 boolean isMinimisation()
           
 void setMaximisation(boolean aFlag)
          Marks the model to be a maximisation problem, or not.
 void setMinimisation(boolean aFlag)
          Marks the model to be a minimisation problem, or not.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.ojalgo.optimisation.OptimisationModel
getDefaultSolver, maximise, minimise
 

Constructor Detail

ConstraintsBasedModel

public ConstraintsBasedModel(Constraint[] someConstraints)

ConstraintsBasedModel

public ConstraintsBasedModel(Set<? extends Constraint> someConstraints)
Method Detail

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