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

Method callbackActive

highs/lp_data/HighsCallback.cpp:63–75  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

61}
62
63bool HighsCallback::callbackActive(const int callback_type) {
64 // Check that callback function has been defined
65 if (!this->user_callback) return false;
66 // Check that callback_type is within range
67 const bool callback_type_ok =
68 callback_type >= kCallbackMin && callback_type <= kCallbackMax;
69 assert(callback_type_ok);
70 if (!callback_type_ok) return false;
71 // Don't call callback if it is not active
72 assert(this->active.size() > 0);
73 if (!this->active[callback_type]) return false;
74 return true;
75}
76
77bool HighsCallback::callbackAction(const int callback_type,
78 std::string message) {

Callers 3

callbackGetCutPoolMethod · 0.80
evaluateRootNodeMethod · 0.80

Calls 1

sizeMethod · 0.45

Tested by

no test coverage detected