Overview | Group | Tree | Graph | Index | Concepts |
ILODEFAULTVISITOR(tx, tc, container)
This macro allows you to define a default visitor for a given object
class tx
and a given container class
tc
.
Within the code of this macro, the function void visit(tx
object)
allows you to specify each visited object.
Here is an example of the actual definition of the default visitor
IloVisitor<IloIntVar,IloIntVarArray>
:
ILODEFAULTVISITOR(IloIntVar,IloIntVarArray,array) { const IloInt size = array.getSize(); for (IloInt i=0; i<size; ++i) visit(array[i]); }
The following default visitors are already defined in Solver:
<IloInt,IloIntArray>
<IloNum,IloNumArray>
<IloBool,IloBoolArray>
<IloIntVar,IloIntVarArray>
<IloNumVar,IloNumVarArray>
<IloBoolVar,IloBoolVarArray>
<IlcIntVar,IlcIntVarArray>
<IlcFloatVar,IlcFloatVarArray>
<IlcInt,IlcIntArray>
<IlcFloat,IlcFloatArray>
For more information, see Selectors.
See Also: