Google OR-Tools v9.11
a fast and portable software suite for combinatorial optimization
|
Parameters for CallbackTest. More...
#include <callback_tests.h>
Public Member Functions | |
CallbackTestParams (SolverType solver_type, bool integer_variables, bool add_lazy_constraints, bool add_cuts, absl::flat_hash_set< CallbackEvent > supported_events, std::optional< SolveParameters > all_solutions, std::optional< SolveParameters > reaches_cut_callback) | |
Public Attributes | |
SolverType | solver_type |
The solver to test. | |
bool | integer_variables |
True if the tests should be performed with integer variables. | |
bool | add_lazy_constraints |
If the solver supports adding lazy constraints at the MIP_SOLUTION event. | |
bool | add_cuts |
If the solver supports adding cuts at the event MIP_NODE. | |
absl::flat_hash_set< CallbackEvent > | supported_events |
The events that should be supported by the solver. | |
std::optional< SolveParameters > | all_solutions |
std::optional< SolveParameters > | reaches_cut_callback |
Friends | |
std::ostream & | operator<< (std::ostream &out, const CallbackTestParams ¶ms) |
Parameters for CallbackTest.
Definition at line 79 of file callback_tests.h.
operations_research::math_opt::CallbackTestParams::CallbackTestParams | ( | SolverType | solver_type, |
bool | integer_variables, | ||
bool | add_lazy_constraints, | ||
bool | add_cuts, | ||
absl::flat_hash_set< CallbackEvent > | supported_events, | ||
std::optional< SolveParameters > | all_solutions, | ||
std::optional< SolveParameters > | reaches_cut_callback ) |
Definition at line 74 of file callback_tests.cc.
|
friend |
Definition at line 108 of file callback_tests.cc.
bool operations_research::math_opt::CallbackTestParams::add_cuts |
If the solver supports adding cuts at the event MIP_NODE.
Definition at line 96 of file callback_tests.h.
bool operations_research::math_opt::CallbackTestParams::add_lazy_constraints |
If the solver supports adding lazy constraints at the MIP_SOLUTION event.
Definition at line 93 of file callback_tests.h.
std::optional<SolveParameters> operations_research::math_opt::CallbackTestParams::all_solutions |
For a small feasibility problem (objective is zero) with <= 10 feasible solutions, ensure the solver finds all solutions.
Definition at line 103 of file callback_tests.h.
bool operations_research::math_opt::CallbackTestParams::integer_variables |
True if the tests should be performed with integer variables.
Definition at line 90 of file callback_tests.h.
std::optional<SolveParameters> operations_research::math_opt::CallbackTestParams::reaches_cut_callback |
Disable as much as possible of presolve, (solver) cuts, and heuristics, so that we can run a custom cut on this problem. Not setting this value will result in the test on adding cuts at event kMipNode not running.
Definition at line 108 of file callback_tests.h.
SolverType operations_research::math_opt::CallbackTestParams::solver_type |
The solver to test.
Definition at line 87 of file callback_tests.h.
absl::flat_hash_set<CallbackEvent> operations_research::math_opt::CallbackTestParams::supported_events |
The events that should be supported by the solver.
Definition at line 99 of file callback_tests.h.