aboutsummaryrefslogtreecommitdiff
path: root/qemu-option.h
diff options
context:
space:
mode:
authorGerd Hoffmann <kraxel@redhat.com>2009-07-31 12:25:32 +0200
committerAnthony Liguori <aliguori@us.ibm.com>2009-08-10 13:05:25 -0500
commit48026075aeca1dc62599a4aaae844edff9679cb4 (patch)
tree7b95f12a30f74a4532f9c618d9e654b1aeb600d8 /qemu-option.h
parentec822001a2f26eef8701194714f6482b6d852de2 (diff)
QemuOpts: add some functions
qemu_opt_foreach: loop over all QemuOpts entries. qemu_opts_id: return QemuOpts id. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com> Message-Id:
Diffstat (limited to 'qemu-option.h')
-rw-r--r--qemu-option.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/qemu-option.h b/qemu-option.h
index 428c947946..56c7eac07d 100644
--- a/qemu-option.h
+++ b/qemu-option.h
@@ -104,11 +104,15 @@ int qemu_opt_get_bool(QemuOpts *opts, const char *name, int defval);
uint64_t qemu_opt_get_number(QemuOpts *opts, const char *name, uint64_t defval);
uint64_t qemu_opt_get_size(QemuOpts *opts, const char *name, uint64_t defval);
int qemu_opt_set(QemuOpts *opts, const char *name, const char *value);
+typedef int (*qemu_opt_loopfunc)(const char *name, const char *value, void *opaque);
+int qemu_opt_foreach(QemuOpts *opts, qemu_opt_loopfunc func, void *opaque,
+ int abort_on_failure);
QemuOpts *qemu_opts_find(QemuOptsList *list, const char *id);
QemuOpts *qemu_opts_create(QemuOptsList *list, const char *id, int fail_if_exists);
int qemu_opts_set(QemuOptsList *list, const char *id,
const char *name, const char *value);
+const char *qemu_opts_id(QemuOpts *opts);
void qemu_opts_del(QemuOpts *opts);
QemuOpts *qemu_opts_parse(QemuOptsList *list, const char *params, const char *firstname);