From 7c47c4ead75d0b733ee8f2f51fd1de0644cc1308 Mon Sep 17 00:00:00 2001 From: Peter Xu Date: Thu, 28 Sep 2017 10:59:54 +0800 Subject: qom: provide root container for internal objs MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit We have object_get_objects_root() to keep user created objects, however no place for objects that will be used internally. Create such a container for internal objects. CC: Andreas Färber CC: Markus Armbruster CC: Paolo Bonzini Suggested-by: Daniel P. Berrange Signed-off-by: Peter Xu Reviewed-by: Fam Zheng Message-id: 20170928025958.1420-2-peterx@redhat.com Signed-off-by: Stefan Hajnoczi --- include/qom/object.h | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'include') diff --git a/include/qom/object.h b/include/qom/object.h index f3e5cff..e0d9824 100644 --- a/include/qom/object.h +++ b/include/qom/object.h @@ -1214,6 +1214,17 @@ Object *object_get_root(void); Object *object_get_objects_root(void); /** + * object_get_internal_root: + * + * Get the container object that holds internally used object + * instances. Any object which is put into this container must not be + * user visible, and it will not be exposed in the QOM tree. + * + * Returns: the internal object container + */ +Object *object_get_internal_root(void); + +/** * object_get_canonical_path_component: * * Returns: The final component in the object's canonical path. The canonical -- cgit v1.1