|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
This interface defines the API for classes that represent optimization models.
An IloModel
extractable is a multiple set of modeling objects,
such as constraints or objectives. Objects of type IloAddable
can be added to and removed from an IloModel
. The modeling
objects in a model can be queried using the iterator returned by method
iterator()
.
An important point is that optimizers such as IloSolverFactory
or
IloCplex
implement the IloModel
interface
through its extension IloModeler
. The model associated with
an optimizer is the model the optimizer will solve upon invocation of its
method solve()
.
Method Summary | |
ilog.concert.IloAddable |
add(ilog.concert.IloAddable object)
This method adds the extractable object to the invoking model. |
ilog.concert.IloAddable[] |
add(ilog.concert.IloAddable[] objects)
This method adds the array of extractable objects to the invoking model. |
ilog.concert.IloAddable[] |
add(ilog.concert.IloAddable[] objects,
int start,
int num)
This method adds modeling objects to the invoking IloModel . |
java.util.Iterator |
iterator()
This method returns an iterator that traverses the objects in the model. |
ilog.concert.IloAddable |
remove(ilog.concert.IloAddable object)
This method removes the extractable object from the invoking model. |
ilog.concert.IloAddable[] |
remove(ilog.concert.IloAddable[] objects)
This method removes the array of extractable objects from the invoking model. |
ilog.concert.IloAddable[] |
remove(ilog.concert.IloAddable[] objects,
int start,
int num)
This method removes modeling objects from the invoking IloModel . |
Methods inherited from interface ilog.concert.IloAddable |
getName, setName |
Method Detail |
public ilog.concert.IloAddable add(ilog.concert.IloAddable object) throws IloException
object
- The modeling object to be added to the invoking IloModel
.
IloException
public ilog.concert.IloAddable[] add(ilog.concert.IloAddable[] objects) throws IloException
objects
- The array of modeling objects to be added to the
invoking IloModel
.
IloException
public ilog.concert.IloAddable[] add(ilog.concert.IloAddable[] objects, int start, int num) throws IloException
IloModel
.
All objects implementing the IloAddable
interface
objects[start]...objects[start+num-1]
are added to
the invoking IloModel
object.
objects
- The array of modeling objects to be added
to the invoking IloModel
.start
- The first modeling object to be added to the
invoking IloModel
.num
- The number of modeling objects to be added to
the invoking IloModel
.
IloException
public ilog.concert.IloAddable remove(ilog.concert.IloAddable object) throws IloException
object
- The modeling object to be removed from the invoking
IloModel
.
IloException
public ilog.concert.IloAddable[] remove(ilog.concert.IloAddable[] objects) throws IloException
objects
- The array of modeling objects to be removed from the
invoking IloModel
.
IloException
public ilog.concert.IloAddable[] remove(ilog.concert.IloAddable[] objects, int start, int num) throws IloException
IloModel
.
The modeling objects or, more precisely, the objects implementing
the IloAddable interface
objects[start]...objects[start+num-1]
are removed
from the invoking IloModel
object. If a modeling object
has been added multiple times, only one instance is removed
from the model.
objects
- The array of modeling objects to be removed
from the invoking IloModel
.start
- The first modeling object to be removed from the
invoking IloModel
.num
- The number of modeling objects to be removed from
the invoking IloModel
.
IloException
public java.util.Iterator iterator()
add, remove
or
the method delete
is called on the invoking
IloModel
.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |