diff options
author | Christian Grothoff <christian@grothoff.org> | 2017-03-15 10:36:51 +0100 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2017-03-15 11:14:59 +0100 |
commit | 7b51d9f06fd6b18f54a4c7f2cbbacfd6e85ba85e (patch) | |
tree | 407c73aebdc2dffcfe0f341493dc7a75a2c442a1 /src/include/gnunet_json_lib.h | |
parent | 85b043ef34186a24d960cb32417da2a610eae526 (diff) | |
download | gnunet-7b51d9f06fd6b18f54a4c7f2cbbacfd6e85ba85e.tar.gz gnunet-7b51d9f06fd6b18f54a4c7f2cbbacfd6e85ba85e.zip |
add json command line option parser
Diffstat (limited to 'src/include/gnunet_json_lib.h')
-rw-r--r-- | src/include/gnunet_json_lib.h | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/src/include/gnunet_json_lib.h b/src/include/gnunet_json_lib.h index 9e5f9e284..ce721d8d8 100644 --- a/src/include/gnunet_json_lib.h +++ b/src/include/gnunet_json_lib.h | |||
@@ -427,6 +427,26 @@ void | |||
427 | GNUNET_JSON_post_parser_cleanup (void *con_cls); | 427 | GNUNET_JSON_post_parser_cleanup (void *con_cls); |
428 | 428 | ||
429 | 429 | ||
430 | /* ****************** GETOPT JSON helper ******************* */ | ||
431 | |||
432 | |||
433 | /** | ||
434 | * Allow user to specify a JSON input value. | ||
435 | * | ||
436 | * @param shortName short name of the option | ||
437 | * @param name long name of the option | ||
438 | * @param argumentHelp help text for the option argument | ||
439 | * @param description long help text for the option | ||
440 | * @param[out] val set to the JSON specified at the command line | ||
441 | */ | ||
442 | struct GNUNET_GETOPT_CommandLineOption | ||
443 | GNUNET_JSON_getopt (char shortName, | ||
444 | const char *name, | ||
445 | const char *argumentHelp, | ||
446 | const char *description, | ||
447 | json_t **json); | ||
448 | |||
449 | |||
430 | #endif | 450 | #endif |
431 | 451 | ||
432 | /* end of gnunet_json_lib.h */ | 452 | /* end of gnunet_json_lib.h */ |