| 10 | static const auto LOGGER = Logger("PropertiesFile"); |
| 11 | |
| 12 | bool getKeyValuePair(const std::string& input, std::string& key, std::string& value) { |
| 13 | auto index = input.find('='); |
| 14 | if (index == std::string::npos) { |
| 15 | return false; |
| 16 | } |
| 17 | key = input.substr(0, index); |
| 18 | value = input.substr(index + 1); |
| 19 | return true; |
| 20 | } |
| 21 | |
| 22 | bool loadPropertiesFile(const std::string& filePath, std::function<void(const std::string& key, const std::string& value)> callback) { |
| 23 | // Reading properties is a common operation; make this debug-level to avoid |
no outgoing calls
no test coverage detected