CPXXNETgetprobname and CPXNETgetprobname
The routine CPXXNETgetprobname/CPXNETgetprobname is used to access the name
of the problem stored in a network problem object.
int CPXXNETgetprobname( CPXCENVptr env, CPXCNETptr net, char * buf_str, CPXSIZE bufspace, CPXSIZE * surplus_p )
int CPXNETgetprobname( CPXCENVptr env, CPXCNETptr net, char * buf_str, int bufspace, int * surplus_p )
Description
The routine CPXXNETgetprobname/CPXNETgetprobname is used to access the name
of the problem stored in a network problem object.
If the routine returns CPXERR_NEGATIVE_SURPLUS, then
the value in *surplus_p
is negative and specifies the difference between the memory
provided and the memory required (in bytes).
Arguments
- env
-
A pointer to the CPLEX environment as returned by
CPXXopenCPLEX/CPXopenCPLEX. - net
-
A pointer to a CPLEX network problem object as returned by
CPXXNETcreateprob/CPXNETcreateprob. - buf_str
- Buffer into which the problem name is copied.
- bufspace
-
Size of the array
buf_strin bytes. - surplus_p
-
Pointer to an integer in which the difference between
bufspaceand the number of bytes required to store the problem name is returned.
Return
The routine returns 0 (zero) on success and nonzero if an error occurs. The value CPXERR_NEGATIVE_SURPLUS specifies that there was not enough space in the buf array to hold the name.
Example
status = CPXNETgetprobname (env, net, name, namesize, &surplus);