In the Callable Library, ILOG CPLEX defines a few special data types for specific ILOG CPLEX objects, as you see in Table 4.1. The types starting with CPXC
represent the corresponding pointers to constant (const
) objects
Table 4.1 Special Data Types in the ILOG CPLEX Callable Library
Data type |
Is a pointer to |
Declaration |
Set by calling |
CPXENVptr CPXCENVptr |
ILOG CPLEX environment |
CPXENVptr env; | |
CPXLPptr CPXCLPptr |
problem object |
CPXLPptr lp; | |
CPXNETptr CPXCNETptr |
problem object |
CPXNETptr net; | |
CPXCHANNELptr |
message channel |
CPXCHANNELptr channel; | |
.
When any of these special variables are set to a value returned by an appropriate routine, that value can be passed directly to other ILOG CPLEX routines that require such parameters. The actual internal type of these variables is a memory address (that is, a pointer); this address uniquely identifies the corresponding object. If you are programming in a language other than C, you should choose an appropriate integer type or pointer type to hold the values of these variables.