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

Function Highs_getOptionName

highs/interfaces/highs_c_api.cpp:412–422  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

410}
411
412HighsInt Highs_getOptionName(const void* highs, const HighsInt index,
413 char** name) {
414 std::string name_v;
415 HighsInt retcode = (HighsInt)((Highs*)highs)->getOptionName(index, &name_v);
416 // Guess we have to add one (for Windows, lol!) because char* is
417 // null-terminated
418 const HighsInt malloc_size = sizeof(char) * (name_v.length() + 1);
419 *name = (char*)malloc(malloc_size);
420 strcpy(*name, name_v.c_str());
421 return retcode;
422}
423
424HighsInt Highs_getBoolOptionValue(const void* highs, const char* option,
425 HighsInt* value) {

Callers 1

fullApiOptionsFunction · 0.85

Calls 2

getOptionNameMethod · 0.80
c_strMethod · 0.80

Tested by 1

fullApiOptionsFunction · 0.68