| 89 | } |
| 90 | |
| 91 | bool ConfigurationHolder::saveNumericToConfigFile(const Configuration & configObject, int nBase) const |
| 92 | { |
| 93 | WCHAR buf[21]; // UINT64_MAX in dec has 20 digits |
| 94 | |
| 95 | if (nBase == 16) |
| 96 | { |
| 97 | swprintf_s(buf, PRINTF_DWORD_PTR_FULL, configObject.getNumeric()); |
| 98 | } |
| 99 | else |
| 100 | { |
| 101 | swprintf_s(buf, PRINTF_INTEGER, configObject.getNumeric()); |
| 102 | } |
| 103 | |
| 104 | BOOL ret = WritePrivateProfileString(CONFIG_FILE_SECTION_NAME, configObject.getName(), buf, configPath); |
| 105 | return !!ret; |
| 106 | } |
| 107 | |
| 108 | bool ConfigurationHolder::readNumericFromConfigFile(Configuration & configObject, int nBase) |
| 109 | { |
nothing calls this directly
no test coverage detected