mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-06 09:13:55 -06:00
qom: New object_property_add_new_container()
To move towards explicit creations of containers, starting that by providing a helper for creating container objects. Signed-off-by: Peter Xu <peterx@redhat.com> Reviewed-by: Markus Armbruster <armbru@redhat.com> Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org> Message-ID: <20241121192202.4155849-3-peterx@redhat.com> Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org>
This commit is contained in:
parent
e469b331cd
commit
6e1e04ef03
2 changed files with 23 additions and 3 deletions
|
@ -2019,6 +2019,18 @@ int object_child_foreach_recursive(Object *obj,
|
|||
*/
|
||||
Object *container_get(Object *root, const char *path);
|
||||
|
||||
/**
|
||||
* object_property_add_new_container:
|
||||
* @obj: the parent object
|
||||
* @name: the name of the parent object's property to add
|
||||
*
|
||||
* Add a newly created container object to a parent object.
|
||||
*
|
||||
* Returns: the newly created container object. Its reference count is 1,
|
||||
* and the reference is owned by the parent object.
|
||||
*/
|
||||
Object *object_property_add_new_container(Object *obj, const char *name);
|
||||
|
||||
/**
|
||||
* object_property_help:
|
||||
* @name: the name of the property
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue