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

Function arg_value

app/server/main.cpp:26–33  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

24}
25
26std::optional<std::string> arg_value(int argc, char ** argv, const std::string & name) {
27 for (int i = 1; i + 1 < argc; ++i) {
28 if (argv[i] == name) {
29 return std::string(argv[i + 1]);
30 }
31 }
32 return std::nullopt;
33}
34
35bool has_arg(int argc, char ** argv, const std::string & name) {
36 for (int i = 1; i < argc; ++i) {

Callers 1

mainFunction · 0.70

Calls 1

stringFunction · 0.50

Tested by

no test coverage detected