summaryrefslogtreecommitdiff
path: root/lib/util/parmlist.h
diff options
context:
space:
mode:
Diffstat (limited to 'lib/util/parmlist.h')
-rw-r--r--lib/util/parmlist.h18
1 files changed, 16 insertions, 2 deletions
diff --git a/lib/util/parmlist.h b/lib/util/parmlist.h
index 0fa518d1c4..47d2f89d63 100644
--- a/lib/util/parmlist.h
+++ b/lib/util/parmlist.h
@@ -31,9 +31,23 @@ struct parmlist {
struct parmlist_entry *entries;
};
+/** Retrieve an integer from a parameter list. If not found, return default_v. */
int parmlist_get_int(struct parmlist *ctx, const char *name, int default_v);
-const char *parmlist_get_string(struct parmlist *ctx, const char *name, const char *default_v);
+
+/** Retrieve a string from a parameter list. If not found, return default_v. */
+const char *parmlist_get_string(struct parmlist *ctx, const char *name,
+ const char *default_v);
+
+/** Retrieve the struct for an entry in a parmlist. */
struct parmlist_entry *parmlist_get(struct parmlist *ctx, const char *name);
-const char **parmlist_get_string_list(struct parmlist *ctx, const char *name, const char *separator);
+
+/** Retrieve a string list from a parameter list.
+ * separator can contain characters to consider separators or can be
+ * NULL for the default set. */
+const char **parmlist_get_string_list(struct parmlist *ctx, const char *name,
+ const char *separator);
+
+/** Retrieve boolean from a parameter list. If not set, return default_v. */
+bool parmlist_get_bool(struct parmlist *ctx, const char *name, bool default_v);
#endif /* _PARMLIST_H */