Previous Page: CPXNETfreeprob First PageNext Page: CPXNETgetarcname

CPXNETgetarcindex


Description

Given a name lname, this function returns the index of the arc with that name (in the network stored in a CPLEX network problem object) to the integer pointed to by index_p.

Return Value

If the operation is successful, CPXNETgetarcindex() returns the value 0; if not, it returns a nonzero value to indicate an error.

Synopsis

int CPXNETgetarcindex (CPXENVptr env,
                       CPXNETptr net,
                       char *lname,
                       int *index_p);

Arguments


CPXENVptr env
The pointer to the CPLEX environment as returned by one of the CPXopenCPLEX() routines.

CPXNETptr net
A pointer to a CPLEX network problem object as returned by CPXNETcreateprob().

char *lname
Name of the arc to look for.

int *index_p
A pointer to an integer in which the arc index will be stored. If the function is successful, *index_p will contain the index number upon function return, otherwise *index_p will be undefined.

Example

status = CPXNETgetarcindex (env, net, "from_a_to_b", &index);

Previous Page: CPXNETfreeprob First PageNext Page: CPXNETgetarcname