This is the base class for user-written callbacks that control branching during the branch-and-cut search.

Namespace: ILOG.OPL
Assembly: oplall (in oplall.dll)

Syntax

C#
public abstract class BranchCallback : Cplex..::..ControlCallback

Remarks

This callback will be called prior to the creation of the children of the current node. It allows you to query how the invoking instance of Cplex is about to create the children, and gives you the opportunity to override this branch creation.

You can create one or two branches by calling one of the makeBranch methods once or twice. It is an error to call makeBranch more than twice.

By calling method prune, you remove the current node from the search tree. In other words, no subnodes from the current node will be added to the search tree. Calling both prune and makeBranch in one invocation of a branch callback is an error and yields unspecified behavior.

If you call neither prune nor makeBranch, the instance of Cplex proceeds with its own branching.

The constructor and methods of this class are protected to make sure that they are used only to derive a user-written callback class or to implement the main method in it.

Inheritance Hierarchy

System..::..Object
  ILOG.OPL..::..Cplex..::..Callback
    ILOG.OPL..::..Cplex..::..MIPInfoCallback
      ILOG.OPL..::..Cplex..::..MIPCallback
        ILOG.OPL..::..Cplex..::..ControlCallback
          ILOG.OPL..::..Cplex..::..BranchCallback

See Also