26 return "MIP_SOLUTION";
46 LOG(FATAL) <<
"Unrecognized callback event: " <<
static_cast<int>(event);
53bool CallbacksMightAddCuts(
const std::vector<MPCallback*>& callbacks) {
54 for (MPCallback*
callback : callbacks) {
63bool CallbacksMightAddLazyConstraints(
64 const std::vector<MPCallback*>& callbacks) {
65 for (MPCallback*
callback : callbacks) {
77 CallbacksMightAddLazyConstraints(callbacks)),
78 callbacks_(callbacks) {}
void RunCallback(MPCallbackContext *context) override
Runs all callbacks from the list given at construction, in sequence.
MPCallbackList(const std::vector< MPCallback * > &callbacks)
bool might_add_lazy_constraints() const
bool might_add_cuts() const
GurobiMPCallbackContext * context
In SWIG mode, we don't want anything besides these top-level includes.
@ kMultiObj
The solver is in multi-objective optimization.
@ kMipSolution
Called every time a new MIP incumbent is found.
@ kMessage
The solver is about to log out a message, use this callback to capture it.
@ kPresolve
The solver is currently running presolve.
@ kSimplex
The solver is currently running the simplex method.
@ kMipNode
Called once per pass of the cut loop inside each MIP node.
@ kBarrier
Called in each iterate of IPM/barrier method.
absl::string_view ToString(MPSolver::OptimizationProblemType optimization_problem_type)