NO FRAMES

CPXNETgetarcname

int CPXPUBLIC CPXNETgetarcname(CPXCENVptr env, CPXCNETptr net, char ** nnames, char * namestore, int namespc, int * surplus_p, int begin, int end)
Definition file: cplex.h
Include files: cplex.h

The routine CPXNETgetarcname is used to access the names of a range of arcs in a network stored in a network problem object. The beginning and end of the range, along with the length of the array in which the arc names are to be returned, must be specified.

Example

 status = CPXNETgetarcname (env, net, nnames, namestore, namespc,
                            &surplus, 0, narcs-1);

Parameters:

env

A pointer to the CPLEX environment as returned by CPXopenCPLEX.

net

A pointer to a CPLEX network problem object as returned by CPXNETcreateprob.

nnames

Where to copy pointers to arc names stored in the namestore array. The length of this array must be at least (end-begin+1). The pointer to the name of arc i is returned in nnames[i-begin].

namestore

Array of characters to which the specified arc names are to be copied. It may be NULL if namespc is 0.

namespc

Length of the namestore array.

surplus_p

Pointer to an integer to which the difference between namespc and the number of characters required to store the requested names is returned. A nonnegative value indicates that namespc was sufficient. A negative value indicates that it was insufficient. In that case, CPXERR_NEGATIVE_SURPLUS is returned and the negative value of surplus_p indicates the amount of insufficient space in the array namestore.

begin

Index of the first arc for which a name is to be obtained.

end

Index of the last arc for which a name is to be obtained.

Returns:

The routine returns zero on success and nonzero if an error occurs. The value CPXERR_NEGATIVE_SURPLUS indicates that insufficient space was available in the namestore array to hold the names.