MCPcopy Create free account
hub / github.com/0xShug0/audio.cpp / parse_positive_i64_option

Function parse_positive_i64_option

src/framework/runtime/options.cpp:178–190  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

176 }
177 throw std::runtime_error(std::string(key) + " must be true/false, yes/no, on/off, or 1/0");
178}
179
180std::optional<int> parse_int_option(
181 const std::unordered_map<std::string, std::string> & options,
182 std::initializer_list<std::string_view> keys) {
183 if (const auto match = find_option_match(options, keys)) {
184 return parse_int_value(match->value, match->key);
185 }
186 return std::nullopt;
187}
188
189std::optional<float> parse_float_option(
190 const std::unordered_map<std::string, std::string> & options,
191 std::initializer_list<std::string_view> keys) {
192 if (const auto match = find_option_match(options, keys)) {
193 return parse_float_value(match->value, match->key);

Callers 3

VoxCPM2SessionMethod · 0.85
make_voice_clone_configFunction · 0.85

Calls 2

find_option_matchFunction · 0.85
parse_i64_valueFunction · 0.85

Tested by

no test coverage detected