mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-04 16:23:55 -06:00
qom: export more functions for use with non-UserCreatable objects
Machines and accelerators are not user-creatable but they are going to share similar command-line parsing machinery. Export functions that will be used with -machine and -accel in softmmu/vl.c. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
This commit is contained in:
parent
d47a8b3b69
commit
3bb6944585
2 changed files with 65 additions and 16 deletions
|
@ -861,6 +861,29 @@ static void do_qemu_init_ ## type_array(void) \
|
|||
} \
|
||||
type_init(do_qemu_init_ ## type_array)
|
||||
|
||||
/**
|
||||
* type_print_class_properties:
|
||||
* @type: a QOM class name
|
||||
*
|
||||
* Print the object's class properties to stdout or the monitor.
|
||||
* Return whether an object was found.
|
||||
*/
|
||||
bool type_print_class_properties(const char *type);
|
||||
|
||||
/**
|
||||
* object_set_properties_from_keyval:
|
||||
* @obj: a QOM object
|
||||
* @qdict: a dictionary with the properties to be set
|
||||
* @from_json: true if leaf values of @qdict are typed, false if they
|
||||
* are strings
|
||||
* @errp: pointer to error object
|
||||
*
|
||||
* For each key in the dictionary, parse the value string if needed,
|
||||
* then set the corresponding property in @obj.
|
||||
*/
|
||||
void object_set_properties_from_keyval(Object *obj, const QDict *qdict,
|
||||
bool from_json, Error **errp);
|
||||
|
||||
/**
|
||||
* object_class_dynamic_cast_assert:
|
||||
* @klass: The #ObjectClass to attempt to cast.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue