Changeset View
Changeset View
Standalone View
Standalone View
src/util/system.cpp
Show First 20 Lines • Show All 591 Lines • ▼ Show 20 Lines | |||||
} | } | ||||
void ArgsManager::ForceSetArg(const std::string &strArg, | void ArgsManager::ForceSetArg(const std::string &strArg, | ||||
const std::string &strValue) { | const std::string &strValue) { | ||||
LOCK(cs_args); | LOCK(cs_args); | ||||
m_override_args[strArg] = {strValue}; | m_override_args[strArg] = {strValue}; | ||||
} | } | ||||
void ArgsManager::ForceSetBoolArg(const std::string &strArg, bool fValue) { | |||||
if (fValue) { | |||||
return ForceSetArg(strArg, std::string("1")); | |||||
} else { | |||||
return ForceSetArg(strArg, std::string("0")); | |||||
} | |||||
} | |||||
/** | /** | ||||
* This function is only used for testing purpose so | * This function is only used for testing purpose so | ||||
* so we should not worry about element uniqueness and | * so we should not worry about element uniqueness and | ||||
* integrity of mapMultiArgs data structure | * integrity of mapMultiArgs data structure | ||||
*/ | */ | ||||
void ArgsManager::ForceSetMultiArg(const std::string &strArg, | void ArgsManager::ForceSetMultiArg(const std::string &strArg, | ||||
const std::string &strValue) { | const std::string &strValue) { | ||||
LOCK(cs_args); | LOCK(cs_args); | ||||
▲ Show 20 Lines • Show All 743 Lines • Show Last 20 Lines |