iparam.h 668 B

1234567891011121314151617181920212223242526272829303132
  1. /** @file iparam.h
  2. *
  3. * @brief Klish scheme's "param" entry
  4. */
  5. #ifndef _klish_iparam_h
  6. #define _klish_iparam_h
  7. #include <faux/error.h>
  8. #include <klish/kparam.h>
  9. typedef struct iparam_s iparam_t;
  10. struct iparam_s {
  11. char *name;
  12. char *help;
  13. char *ptype;
  14. char *mode;
  15. iparam_t * (*params)[]; // Nested PARAMs
  16. };
  17. C_DECL_BEGIN
  18. bool_t iparam_parse(const iparam_t *info, kparam_t *param, faux_error_t *error);
  19. bool_t iparam_parse_nested(const iparam_t *iparam, kparam_t *kparam,
  20. faux_error_t *error);
  21. kparam_t *iparam_load(const iparam_t *iparam, faux_error_t *error);
  22. char *iparam_deploy(const kparam_t *kparam, int level);
  23. C_DECL_END
  24. #endif // _klish_iparam_h