MCPcopy Create free account
hub / github.com/CalcProgrammer1/OpenRGB / GetSettings

Method GetSettings

SettingsManager.cpp:28–46  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

26}
27
28json SettingsManager::GetSettings(std::string settings_key)
29{
30 /*---------------------------------------------------------*\
31 | Check to see if the key exists in the settings store and |
32 | return the settings associated with the key if it exists |
33 \*---------------------------------------------------------*/
34 if(settings_data.contains(settings_key))
35 {
36 return(settings_data[settings_key]);
37 }
38
39 /*---------------------------------------------------------*\
40 | If the settings store doesn't contain the key, create an |
41 | empty json and return it |
42 \*---------------------------------------------------------*/
43 json empty;
44
45 return(empty);
46}
47
48void SettingsManager::SetSettings(std::string settings_key, json new_settings)
49{

Callers 15

ResourceManagerMethod · 0.80
AddPluginMethod · 0.80
DetectRazerControllersFunction · 0.80
DetectDebugControllersFunction · 0.80

Calls 1

containsMethod · 0.80

Tested by

no test coverage detected