| Overview | Group | Tree | Graph | Index | Concepts |

For each basic type, Concert Technology defines a corresponding array class.
IloAnyVarArray is the array class of the enumerated variable class
(IloAnyVar) for a model. The parent class for
IloAnyVarArray is the class IloExtractableArray.
Instances of IloAnyVarArray are extensible. That is, you can add more
elements to such an array. References to an array change whenever an element is added
or removed from the array.
Most member functions in this class contain assert statements. For an
explanation of the macro NDEBUG (a way to turn on or turn off these
assert statements), see the concept
Assert and NDEBUG.
See Also:
IloAnyVar, IloModel, operator<<
| Constructor Summary | |
|---|---|
public | IloAnyVarArray(IloDefaultArrayI * i=0) |
public | IloAnyVarArray(const IloEnv env, IloInt n=0) |
| Method Summary | |
|---|---|
public void | add(IloInt more, const IloAnyVar x) |
public void | add(const IloAnyVar x) |
public void | add(const IloAnyVarArray array) |
public IloAnyVar | operator[](IloInt i) const |
public IloAnyVar & | operator[](IloInt i) |
Inherited Methods from IloExtractableArray |
|---|
add, add, add, endElements, setNames |
| Constructor Detail |
|---|
This constructor creates an empty extensible array
of enumerated variables. You
cannot create instances of the undocumented class
IloDefaultArrayI. As an argument
in this default constructor, it allows you to pass 0 (zero) as a value to an
optional argument in functions and member functions that accept an array as
an argument.
This constructor creates an extensible array of n enumerated variables.
Initially, the n elements are empty handles.
| Method Detail |
|---|
This member function appends x to the invoking array
multiple times. The argument more specifies how many
times.
This member function appends x to the invoking array.
This member function appends the elements in array to the invoking
array.
This operator returns a reference to the object
located in the invoking array at the position
specified by the index i.
On const arrays,
Concert Technology uses the const operator:
IloAnyVar operator[] (IloInt i) const;
This operator returns a reference to the object
located in the invoking array at the position
specified by the index i.