MCPcopy Create free account
hub / github.com/ERGO-Code/HiGHS / stopCallback

Method stopCallback

highs/lp_data/Highs.cpp:2696–2712  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2694}
2695
2696HighsStatus Highs::stopCallback(const int callback_type) {
2697 const bool callback_type_ok =
2698 callback_type >= kCallbackMin && callback_type <= kCallbackMax;
2699 assert(callback_type_ok);
2700 if (!callback_type_ok) return HighsStatus::kError;
2701 if (!this->callback_.user_callback) {
2702 highsLogUser(options_.log_options, HighsLogType::kWarning,
2703 "Cannot stop callback when user_callback not defined\n");
2704 return HighsStatus::kWarning;
2705 }
2706 assert(int(this->callback_.active.size()) == kNumCallbackType);
2707 this->callback_.active[callback_type] = false;
2708 // Possibly modify the logging callback activity
2709 if (callback_type == kCallbackLogging)
2710 options_.log_options.user_callback_active = false;
2711 return HighsStatus::kOk;
2712}
2713
2714HighsStatus Highs::stopCallback(const HighsCallbackType callback_type) {
2715 const bool callback_type_ok =

Callers 8

getIisInterfaceMethod · 0.95
Highs_stopCallbackFunction · 0.80
unsubscribeMethod · 0.80
unsubscribe_by_dataMethod · 0.80
clearMethod · 0.80
TestIO.cppFile · 0.80
runMipUserSolutionTestFunction · 0.80

Calls 2

highsLogUserFunction · 0.85
sizeMethod · 0.45

Tested by 1

runMipUserSolutionTestFunction · 0.64