CPXXcallbacksetnodeuserhandle and CPXcallbacksetnodeuserhandle
The routine CPXXcallbacksetnodeuserhandle/CPXcallbacksetnodeuserhandle sets the user
handle for the node specified by nodeindex and optionally
returns the old user handle stored at that node.
int CPXXcallbacksetnodeuserhandle( CPXCENVptr env, void * cbdata, int wherefrom, CPXCNT nodeindex, void * userhandle, void ** olduserhandle_p )
int CPXcallbacksetnodeuserhandle( CPXCENVptr env, void * cbdata, int wherefrom, int nodeindex, void * userhandle, void ** olduserhandle_p )
Description
This is an advanced routine. Advanced routines typically demand a thorough understanding of the algorithms used by CPLEX. Thus they incur a higher risk of incorrect behavior in your application, behavior that can be difficult to debug. Therefore, the team encourages you to consider carefully whether you can accomplish the same task by means of other Callable Library routines instead.
Although the name of this routine matches the naming pattern of the generic callback, you must not use this routine with that generic callback. Use this routine only with legacy callbacks.
The routine CPXXcallbacksetnodeuserhandle/CPXcallbacksetnodeuserhandle sets the user
handle for the node specified by nodeindex and optionally
returns the old user handle stored at that node. Invoke
this routine only from the legacy node selection callback.
This routine can not change the user handle of nodes
that are swapped out to disk.
Arguments
- env
-
A pointer to the CPLEX environment, as returned by
CPXXopenCPLEX/CPXopenCPLEX. - cbdata
-
The pointer passed to the user-written callback.
This argument must be the value of
cbdatapassed to the user-written callback. - wherefrom
-
An integer value reporting from where the user-written callback was called.
This argument must be the value of
wherefrompassed to the user-written callback. - nodeindex
-
The index of the node for which the user handle is to be changed.
Nodes are indexed from
0(zero) to(nodecount -1)wherenodecountis obtained from the legacy callback information routineCPXXgetcallbackinfo/CPXgetcallbackinfo, with awhichinfovalue ofCPX_CALLBACK_INFO_NODES_LEFT. - userhandle
- The new user handle for the specified node.
- olduserhandle_p
-
If this argument is not
NULL, then CPLEX stores here the old user handle of the specified node.