> Advanced Programming Techniques > Using Callbacks

This chapter introduces callbacks. Callbacks allow you to monitor closely and to guide the behavior of ILOG CPLEX optimizers. In particular, ILOG CPLEX callbacks allow user code to be executed regularly during an optimization. To use callbacks with ILOG CPLEX, you must first write the callback function, and then pass it to ILOG CPLEX. There are two types of callbacks: diagnostic callbacks and control callbacks. You will find additional information about callbacks in this manual in Advanced MIP Control Interface. This chapter includes information about:

Notes
The callback class hierarchy for Java and C#.NET is exactly the same as the hierarchy for C++, but the class names differ, in that there is no I at the end. For example, the Java implementation class corresponding to the C++ class IloCplex::ContinuousCallbackI is IloCplex.ContinuousCallback. The names of callback classes in C#.NET correspond very closely to those in the Java API. However, the name of a C#.NET class does not begin with Ilo. Furthermore, the names of C#.NET methods are capitalized (that is, they begin with an uppercase character) according to .NET conventions. For example, the corresponding callback class in C#.NET is Cplex.ContinuousCallback.