blob: 9d0f5e4cbca630f8789c430b019ea2f8742f6e74 [file] [log] [blame]
#pragma once
#include <osmocom/core/linuxlist.h>
/* a single node in the tree of values */
struct value_node {
/* our element in the parent list */
struct llist_head list;
/* the display name */
const char *name;
/* the value (if any) */
const char *value;
/* the children (if value == NULL) */
struct llist_head children;
};
struct value_node *value_node_add(void *ctx, struct value_node *parent,
const char *name, const char *value);
struct value_node *value_node_find(struct value_node *parent, const char *name);
struct value_node *value_node_find_or_add(struct value_node *parent, const char *name);
void value_node_del(struct value_node *node);