summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorPaolo Bonzini <pbonzini@redhat.com>2012-05-02 13:30:54 +0200
committerAndreas Färber <afaerber@suse.de>2012-06-18 15:14:36 +0200
commite7cce67f27bce49d8b6d09f4e66059d1fd117ebb (patch)
tree3f2326a6d93512115b94138424a162d29130ecd4 /include
parenteb2aeacf983a2a88a2b31e8fee067c38bd10abd3 (diff)
qom: Add object_class_get_parent()
This simple bit of functionality was missing and we'll need it soon, so add it. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> Reviewed-by: Anthony Liguori <aliguori@us.ibm.com> [AF: Document possible NULL return value] Signed-off-by: Andreas Färber <afaerber@suse.de>
Diffstat (limited to 'include')
-rw-r--r--include/qemu/object.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/include/qemu/object.h b/include/qemu/object.h
index d93b77293..487559c5c 100644
--- a/include/qemu/object.h
+++ b/include/qemu/object.h
@@ -548,6 +548,14 @@ ObjectClass *object_class_dynamic_cast(ObjectClass *klass,
const char *typename);
/**
+ * object_class_get_parent:
+ * @klass: The class to obtain the parent for.
+ *
+ * Returns: The parent for @klass or %NULL if none.
+ */
+ObjectClass *object_class_get_parent(ObjectClass *klass);
+
+/**
* object_class_get_name:
* @klass: The class to obtain the QOM typename for.
*