Lines Matching full:the
9 * This work is licensed under the terms of the GNU GPL, version 2 or later.
10 * See the COPYING file in the top-level directory.
35 * @obj: the object that owns the property
36 * @v: the visitor that contains the property data
37 * @name: the name of the property
38 * @opaque: the object property opaque
51 * @obj: the object that owns the property
52 * @opaque: the opaque registered with the property
53 * @part: the name of the property
55 * Resolves the #Object corresponding to property @part.
57 * The returned object can also be used as a starting point
60 * Returns: If @path is the path that led to @obj, the function
61 * returns the #Object corresponding to "@path/@part".
70 * @obj: the object that owns the property
71 * @name: the name of the property
72 * @opaque: the opaque registered with the property
82 * @obj: the object that owns the property
83 * @prop: the property to set
105 * @obj: the object that is being removed from the composition tree
107 * Called when an object is being removed from the QOM composition tree.
108 * The function should remove any backlinks from children objects to @obj.
114 * @obj: the object being freed
125 * The base for all classes. The only thing that #ObjectClass contains is an
145 * The base for all objects. The first member of this object is a pointer to
146 * a #ObjectClass. Since C guarantees that the first member of a structure
148 * its parent as the first member, we can cast directly to a #Object.
150 * As a result, #Object contains a reference to the objects type as its
151 * first member. This allows identification of the real type of the object at
167 * @OBJ_NAME: the object name in uppercase with underscore separators
170 * Direct usage of this macro should be avoided, and the complete
173 * This macro will provide the instance type cast functions for a
184 * @OBJ_NAME: the object name in uppercase with underscore separators
187 * Direct usage of this macro should be avoided, and the complete
190 * This macro will provide the class type cast functions for a
206 * @OBJ_NAME: the object name in uppercase with underscore separators
209 * Direct usage of this macro should be avoided, and the complete
212 * This macro will provide the three standard type cast functions for a
224 * @MODULE_OBJ_NAME: the object name in uppercase with underscore separators
228 * - create the typedefs for the object and class structs
229 * - register the type for use with g_autoptr
232 * The object struct and class struct need to be declared manually.
246 * @MODULE_OBJ_NAME: the object name in uppercase with underscore separators
248 * This does the same as OBJECT_DECLARE_TYPE(), but with no class struct
251 * This macro should be used unless the class struct needs to have
264 * @ModuleObjName: the object name with initial caps
265 * @module_obj_name: the object name in lowercase with underscore separators
266 * @MODULE_OBJ_NAME: the object name in uppercase with underscore separators
267 * @PARENT_MODULE_OBJ_NAME: the parent object name in uppercase with underscore
269 * @ABSTRACT: boolean flag to indicate whether the object can be instantiated
270 * @CLASS_SIZE: size of the type's class
273 * This is the base macro used to implement all the OBJECT_DEFINE_*
309 * @ModuleObjName: the object name with initial caps
310 * @module_obj_name: the object name in lowercase with underscore separators
311 * @MODULE_OBJ_NAME: the object name in uppercase with underscore separators
312 * @PARENT_MODULE_OBJ_NAME: the parent object name in uppercase with underscore
314 * @ABSTRACT: boolean flag to indicate whether the object can be instantiated
320 * - declare the TypeInfo struct instance
321 * - provide the constructor to register the type
323 * After using this macro, implementations of the _finalize, _class_init,
327 * This macro should rarely be used, instead one of the more specialized
340 * @ModuleObjName: the object name with initial caps
341 * @module_obj_name: the object name in lowercase with underscore separators
342 * @MODULE_OBJ_NAME: the object name in uppercase with underscore separators
343 * @PARENT_MODULE_OBJ_NAME: the parent object name in uppercase with underscore
347 * for the common case of a non-abstract type, without any interfaces.
357 * @ModuleObjName: the object name with initial caps
358 * @module_obj_name: the object name in lowercase with underscore separators
359 * @MODULE_OBJ_NAME: the object name in uppercase with underscore separators
360 * @PARENT_MODULE_OBJ_NAME: the parent object name in uppercase with underscore
365 * for the common case of a non-abstract type, with one or more implemented
368 * Note when passing the list of interfaces, be sure to include the final
380 * @ModuleObjName: the object name with initial caps
381 * @module_obj_name: the object name in lowercase with underscore separators
382 * @MODULE_OBJ_NAME: the object name in uppercase with underscore separators
383 * @PARENT_MODULE_OBJ_NAME: the parent object name in uppercase with underscore
397 * @ModuleObjName: the object name with initial caps
398 * @module_obj_name: the object name in lowercase with underscore separators
399 * @MODULE_OBJ_NAME: the object name in uppercase with underscore separators
400 * @PARENT_MODULE_OBJ_NAME: the parent object name in uppercase with underscore
404 * the case of a non-abstract type, with interfaces, and with no requirement
417 * @ModuleObjName: the object name with initial caps
418 * @module_obj_name: the object name in lowercase with underscore separators
419 * @MODULE_OBJ_NAME: the object name in uppercase with underscore separators
420 * @PARENT_MODULE_OBJ_NAME: the parent object name in uppercase with underscore
424 * the common case of a non-abstract type, without any interfaces, and with
426 * OBJECT_DECLARE_SIMPLE_TYPE then this is probably the right choice for
436 * @name: The name of the type.
437 * @parent: The name of the parent type.
438 * @instance_size: The size of the object (derivative of #Object). If
439 * @instance_size is 0, then the size of the object will be the size of the
441 * @instance_align: The required alignment of the object. If @instance_align
444 * @instance_init: This function is called to initialize an object. The parent
445 * class will have already been initialized so the type is only responsible
449 * @instance_post_init functions for the parent classes.
451 * is called before the parent @instance_finalize function has been called.
452 * An object should only free the members that are unique to its type in this
454 * @abstract: If this field is true, then the class is considered abstract and
456 * @class_size: The size of the class object (derivative of #ObjectClass)
457 * for this object. If @class_size is 0, then the size of the class will be
458 * assumed to be the size of the parent class. This allows a type to avoid
463 * This is also the function to use to override virtual methods from a parent
466 * parent class initialization has occurred, but before the class itself
467 * is initialized. This is the function to use to undo the effects of
468 * memcpy from the parent class to the descendants.
469 * @class_data: Data to pass to the @class_init,
472 * @interfaces: The list of interfaces associated with this type. This
519 * @type: The C type to use for the return value.
521 * @name: The QOM typename of @type
536 * @class_type: The C type to use for the return value.
538 * @name: the QOM typename of @class_type.
550 * @class: The C type to use for the return value.
551 * @obj: The object to obtain the class for.
552 * @name: The QOM typename of @obj.
563 * @type: The name of the interface.
565 * The information associated with an interface.
573 * @parent_class: the base class
575 * The class for all interfaces. Subclasses of this class should only add
578 * Note that most of the fields of ObjectClass are unused (all except
601 * @interface: the type to return
602 * @obj: the object to convert to an interface
603 * @name: the interface type name
613 * @klass: The class to instantiate.
616 * The returned object has a reference count of 1, and will be freed when
617 * the last reference is dropped.
619 * Returns: The newly allocated and instantiated object.
625 * @typename: The name of the type of the object to instantiate.
628 * The returned object has a reference count of 1, and will be freed when
629 * the last reference is dropped.
631 * Returns: The newly allocated and instantiated object.
637 * @typename: The name of the type of the object to instantiate.
638 * @parent: the parent object
639 * @id: The unique ID of the object
644 * The returned object has a reference count of 1, and will be freed when
645 * the last reference is dropped.
647 * The @id parameter will be used when registering the object as a
648 * child of @parent in the composition tree.
650 * The variadic parameters are a list of pairs of (propname, propvalue)
651 * strings. The propname of %NULL indicates the end of the property
652 * list. If the object implements the user creatable interface, the
653 * object will be marked complete once all the properties have been
676 * The returned object will have one stable reference maintained
677 * for as long as it is present in the object hierarchy.
679 * Returns: The newly allocated, instantiated & initialized object.
689 * @typename: The name of the type of the object to instantiate.
690 * @parent: the parent object
691 * @id: The unique ID of the object
713 * @obj: the object instance to set properties on
720 * The variadic parameters are a list of pairs of (propname, propvalue)
721 * strings. The propname of %NULL indicates the end of the property
740 * The returned object will have one stable reference maintained
741 * for as long as it is present in the object hierarchy.
749 * @obj: the object instance to set properties on
761 * @obj: A pointer to the memory to be used for the object.
762 * @size: The maximum size available at @obj for the object.
763 * @typename: The name of the type of the object to instantiate.
765 * This function will initialize an object. The memory for the object should
766 * have already been allocated. The returned object has a reference count of 1,
767 * and will be finalized when the last reference is dropped.
773 * @parentobj: The parent object to add a property to
774 * @propname: The name of the property
775 * @childobj: A pointer to the memory to be used for the object.
776 * @size: The maximum size available at @childobj for the object.
777 * @type: The name of the type of the object to instantiate.
778 * @errp: If an error occurs, a pointer to an area to store the error
781 * This function will initialize an object. The memory for the object should
782 * have already been allocated. The object will then be added as child property
783 * to a parent with object_property_add_child() function. The returned object
784 * has a reference count of 1 (for the "child<...>" property from the parent),
785 * so the object will be finalized automatically when the parent gets removed.
787 * The variadic parameters are a list of pairs of (propname, propvalue)
788 * strings. The propname of %NULL indicates the end of the property list.
789 * If the object implements the user creatable interface, the object will
790 * be marked complete once all the properties have been processed.
801 * @parentobj: The parent object to add a property to
802 * @propname: The name of the property
803 * @childobj: A pointer to the memory to be used for the object.
804 * @size: The maximum size available at @childobj for the object.
805 * @type: The name of the type of the object to instantiate.
806 * @errp: If an error occurs, a pointer to an area to store the error
820 * @parent: The parent object to add a property to
821 * @propname: The name of the property
822 * @child: A precisely typed pointer to the memory to be used for the
824 * @type: The name of the type of the object to instantiate.
841 * @obj: The object to cast.
842 * @typename: The @typename to cast to.
853 * @obj: The object to cast.
854 * @typename: The @typename to cast to.
859 * See object_dynamic_cast() for a description of the parameters of this
860 * function. The only difference in behavior is that this function asserts
863 * the wrapper macro OBJECT_CHECK.
872 * Returns: The #ObjectClass of the type associated with @obj.
880 * Returns: The QOM typename of @obj.
886 * @info: The #TypeInfo of the new type.
888 * Returns: the new #Type.
894 * @infos: The array of the new type #TypeInfo structures.
897 * @infos and all of the strings it points to should exist for the life time
898 * that the type is registered.
904 * @type_array: The array containing #TypeInfo structures to register
906 * @type_array should be static constant that exists for the life time
907 * that the type is registered.
920 * Print the object's class properties to stdout or the monitor.
928 * @qdict: a dictionary with the properties to be set
933 * For each key in the dictionary, parse the value string if needed,
934 * then set the corresponding property in @obj.
941 * @klass: The #ObjectClass to attempt to cast.
942 * @typename: The QOM typename of the class to cast to.
947 * See object_class_dynamic_cast() for a description of the parameters
948 * of this function. The only difference in behavior is that this function
951 * the wrapper macro OBJECT_CLASS_CHECK.
960 * @klass: The #ObjectClass to attempt to cast.
961 * @typename: The QOM typename of the class to cast to.
966 * If @typename is an interface, this function returns the interface
968 * is returned if @klass does not implement the interface or if multiple
969 * classes or interfaces on the hierarchy leading to @klass implement
977 * @klass: The class to obtain the parent for.
979 * Returns: The parent for @klass or %NULL if none.
985 * @klass: The class to obtain the QOM typename for.
987 * Returns: The QOM typename for @klass.
993 * @klass: The class to obtain the abstractness for.
1001 * @typename: The QOM typename to obtain the class for.
1003 * Returns: The class for @typename or %NULL if not found.
1009 * @typename: The QOM typename to obtain the class for.
1012 * object_class_by_name, but additionally tries to load the module
1013 * needed in case the class is not available.
1015 * Returns: The class for @typename or %NULL if not found.
1025 * @implements_type: The type to filter for, including its derivatives.
1028 * Returns: A singly-linked list of the classes in reverse hashtable order.
1035 * @implements_type: The type to filter for, including its derivatives.
1038 * Returns: A singly-linked list of the classes in alphabetical
1046 * @obj: the object
1048 * Increase the reference count of a object. A object cannot be freed as long
1056 * @obj: the object
1058 * Decrease the reference count of a object. A object cannot be freed as long
1065 * @obj: the object to add a property to
1066 * @name: the name of the property. This can contain any character except for
1069 * @type: the type name of the property. This namespace is pretty loosely
1071 * to angle brackets. For instance, the type 'virtio-net-pci' in the
1073 * @get: The getter to be called to read a property. If this is NULL, then
1074 * the property cannot be read.
1075 * @set: the setter to be called to write a property. If this is NULL,
1076 * then the property cannot be written.
1077 * @release: called when the property is removed from the object. This is
1080 * @opaque: an opaque pointer to pass to the callbacks for the property
1083 * Returns: The #ObjectProperty; this can be used to set the @resolve
1098 * @obj: the object to add a property to
1099 * @name: the name of the property. This can contain any character except for
1102 * @type: the type name of the property. This namespace is pretty loosely
1104 * to angle brackets. For instance, the type 'virtio-net-pci' in the
1106 * @get: The getter to be called to read a property. If this is NULL, then
1107 * the property cannot be read.
1108 * @set: the setter to be called to write a property. If this is NULL,
1109 * then the property cannot be written.
1110 * @release: called when the property is removed from the object. This is
1113 * @opaque: an opaque pointer to pass to the callbacks for the property
1133 * @prop: the property to set
1134 * @value: the value to be written to the property
1136 * Set the property default value.
1142 * @prop: the property to set
1143 * @value: the value to be written to the property
1145 * Set the property default value.
1151 * @prop: the property to set
1153 * Set the property default value to be an empty list.
1159 * @prop: the property to set
1160 * @value: the value to be written to the property
1162 * Set the property default value.
1168 * @prop: the property to set
1169 * @value: the value to be written to the property
1171 * Set the property default value.
1177 * @obj: the object
1178 * @name: the name of the property
1188 * @obj: the object
1189 * @name: the name of the property
1202 * @klass: the object class
1203 * @name: the name of the property
1214 * @klass: the object class
1215 * @name: the name of the property
1233 * @iter: the iterator instance
1234 * @obj: the object
1239 * It is forbidden to modify the property list while iterating,
1260 * @iter: the iterator instance
1261 * @klass: the class
1266 * It is forbidden to modify the property list while iterating,
1277 * @iter: the iterator instance
1279 * Return the next available property. If no further properties
1280 * are available, a %NULL value will be returned and the @iter
1284 * Returns: the next property, or %NULL when all properties
1293 * @obj: the object
1294 * @name: the name of the property
1295 * @v: the visitor that will receive the property value. This should be an
1296 * Output visitor and the data will be written with @name as the name.
1308 * @obj: the object
1309 * @name: the name of the property
1310 * @value: the value to be written to the property
1322 * @obj: the object
1323 * @name: the name of the property
1326 * Returns: the value of the property, converted to a C string, or NULL if
1327 * an error occurs (including when the property value is not a string).
1328 * The caller should free the string.
1335 * @obj: the object
1336 * @name: the name of the property
1337 * @value: the value to be written to the property
1342 * If the link property was created with
1343 * %OBJ_PROP_LINK_STRONG bit, the old target object is
1344 * unreferenced, and a reference is added to the new target object.
1353 * @obj: the object
1354 * @name: the name of the property
1357 * Returns: the value of the property, resolved from a path to an Object,
1358 * or NULL if an error occurs (including when the property value is not a
1366 * @obj: the object
1367 * @name: the name of the property
1368 * @value: the value to be written to the property
1380 * @obj: the object
1381 * @name: the name of the property
1384 * Returns: the value of the property, converted to a boolean, or false if
1385 * an error occurs (including when the property value is not a bool).
1392 * @obj: the object
1393 * @name: the name of the property
1394 * @value: the value to be written to the property
1406 * @obj: the object
1407 * @name: the name of the property
1410 * Returns: the value of the property, converted to an integer, or -1 if
1411 * an error occurs (including when the property value is not an integer).
1418 * @obj: the object
1419 * @name: the name of the property
1420 * @value: the value to be written to the property
1432 * @obj: the object
1433 * @name: the name of the property
1436 * Returns: the value of the property, converted to an unsigned integer, or 0
1437 * an error occurs (including when the property value is not an integer).
1444 * @obj: the object
1445 * @name: the name of the property
1446 * @typename: the name of the enum data type
1449 * Returns: the value of the property, converted to an integer (which
1450 * can't be negative), or -1 on error (including when the property
1458 * @obj: the object
1459 * @name: the name of the property
1460 * @v: the visitor that will be used to write the property value. This should
1461 * be an Input visitor and the data will be first read with @name as the
1462 * name and then written as the property value.
1474 * @obj: the object
1475 * @name: the name of the property
1476 * @string: the string that will be used to parse the property value.
1479 * Parses a string and writes the result into a property of an object.
1488 * @obj: the object
1489 * @name: the name of the property
1493 * Returns a string representation of the value of the property. The
1494 * caller shall free the string.
1501 * @obj: the object
1502 * @name: the name of the property
1505 * Returns: The type name of the property.
1513 * Returns: the root object of the composition tree
1519 * @name: the name of container to lookup
1523 * Returns: the container with @name.
1531 * Get the container object that holds user created
1532 * object instances. This is the object at path
1535 * Returns: the user object container
1542 * Get the container object that holds internally used object
1544 * user visible, and it will not be exposed in the QOM tree.
1546 * Returns: the internal object container
1552 * @obj: the object
1554 * Returns: The final component in the object's canonical path. The canonical
1555 * path is the path within the composition tree starting from the root.
1556 * %NULL if the object doesn't have a parent (and thus a canonical path).
1562 * @obj: the object
1564 * Returns: The canonical path for a object, newly allocated. This is
1565 * the path within the composition tree starting from the root. Use
1572 * @path: the path to resolve
1573 * @ambiguous: (out) (optional): location to store whether the lookup failed
1578 * Absolute paths are derived from the root object and can follow child<> or
1584 * prefix. The matching rules for partial paths are subtle but designed to make
1585 * specifying objects easy. At each level of the composition tree, the partial
1586 * path is matched as an absolute path. The first match is not returned. At
1589 * returned to indicate that the match was ambiguous.
1591 * Returns: The matched object or %NULL on path lookup failure.
1597 * @path: the path to resolve
1598 * @typename: the type to look for.
1599 * @ambiguous: (out) (optional): location to store whether the lookup failed
1603 * partial path only matches that implement the given type are considered.
1604 * This restricts the search and avoids spuriously flagging matches as
1607 * For both partial and absolute paths, the return value goes through
1608 * a dynamic cast to @typename. This is important if either the link,
1609 * or the typename itself are of interface types.
1611 * Returns: The matched object or NULL on path lookup failure.
1618 * @typename: the type to look for
1621 * Return the only object in the QOM tree of type @typename.
1625 * Returns: The matched object or NULL on path lookup failure.
1631 * @parent: the object in which to resolve the path
1632 * @path: the path to resolve
1637 * Returns: The resolved object or NULL on path lookup failure.
1643 * @parent: the object in which to resolve the path
1644 * @part: the component to resolve.
1647 * only resolves one element (@part) and takes the others from @parent.
1649 * Returns: The resolved object or NULL on path lookup failure.
1655 * @obj: the object to add a property to
1656 * @name: the name of the property
1657 * @child: the child object
1660 * Child properties form the composition tree. All objects need to be a child
1666 * The value of a child property as a C string will be the child object's
1668 * The child object itself can be retrieved using object_property_get_link().
1670 * Returns: The newly added property on success, or %NULL on failure.
1677 * @obj: the object to add a property to
1678 * @name: the name of the property
1679 * @child: the child object
1688 /* Unref the link pointer when the property is deleted */
1698 * @obj: the object to add a property to
1699 * @name: the name of the property
1700 * @child: the child object
1703 * The default implementation of the object_property_add_link() check()
1704 * callback function. It allows the link property to be set and never returns
1712 * @obj: the object to add a property to
1713 * @name: the name of the property
1714 * @type: the qobj type of the link
1715 * @targetp: a pointer to where the link object reference is stored
1716 * @check: callback to veto setting or NULL if the property is read-only
1717 * @flags: additional options for the link
1723 * Links form the graph in the object model.
1725 * The @check() callback is invoked when
1726 * object_property_set_link() is called and can raise an error to prevent the
1727 * link being set. If @check is NULL, the property is read-only
1730 * Ownership of the pointer that @child points to is transferred to the
1731 * link property. The reference count for *@child is
1732 * managed by the property from after the function returns till the
1733 * property is deleted with object_property_del(). If the
1735 * the reference count is decremented when the property is deleted or
1738 * Returns: The newly added property on success, or %NULL on failure.
1755 * @obj: the object to add a property to
1756 * @name: the name of the property
1757 * @get: the getter or NULL if the property is write-only. This function must
1759 * @set: the setter or NULL if the property is read-only
1764 * Returns: The newly added property on success, or %NULL on failure.
1778 * @obj: the object to add a property to
1779 * @name: the name of the property
1780 * @get: the getter or NULL if the property is write-only.
1781 * @set: the setter or NULL if the property is read-only
1786 * Returns: The newly added property on success, or %NULL on failure.
1799 * @obj: the object to add a property to
1800 * @name: the name of the property
1801 * @typename: the name of the enum data type
1803 * @get: the getter or %NULL if the property is write-only.
1804 * @set: the setter or %NULL if the property is read-only
1809 * Returns: The newly added property on success, or %NULL on failure.
1826 * @obj: the object to add a property to
1827 * @name: the name of the property
1828 * @get: the getter or NULL if the property is write-only.
1833 * Returns: The newly added property on success, or %NULL on failure.
1843 /* Automatically add a getter to the property */
1845 /* Automatically add a setter to the property */
1847 /* Automatically add a getter and a setter to the property */
1853 * @obj: the object to add a property to
1854 * @name: the name of the property
1861 * Returns: The newly added property on success, or %NULL on failure.
1874 * @obj: the object to add a property to
1875 * @name: the name of the property
1882 * Returns: The newly added property on success, or %NULL on failure.
1895 * @obj: the object to add a property to
1896 * @name: the name of the property
1903 * Returns: The newly added property on success, or %NULL on failure.
1916 * @obj: the object to add a property to
1917 * @name: the name of the property
1924 * Returns: The newly added property on success, or %NULL on failure.
1937 * @obj: the object to add a property to
1938 * @name: the name of the property
1939 * @target_obj: the object to forward property access to
1940 * @target_name: the name of the property on the forwarded object
1943 * of the same type as the forwarded property.
1945 * The caller must ensure that @target_obj stays alive as long as
1946 * this property exists. In the case of a child object or an alias on the same
1947 * object this will be the case. For aliases to other objects the caller is
1950 * Returns: The newly added property on success, or %NULL on failure.
1957 * @obj: the object to add a property to
1958 * @name: the name of the property
1959 * @target: the object to be referred by the link
1962 * add a property of type link<TYPE> where TYPE is the type of @target.
1964 * The caller must ensure that @target stays alive as long as
1965 * this property exists. In the case @target is a child of @obj,
1966 * this will be the case. Otherwise, the caller is responsible for
1969 * Returns: The newly added property on success, or %NULL on failure.
1976 * @obj: the object owning the property
1977 * @name: the name of the property
1978 * @description: the description of the property on the object
1991 * @obj: the object whose children will be navigated
1992 * @fn: the iterator function to be called
1993 * @opaque: an opaque value that will be passed to the iterator
1998 * It is forbidden to add or remove children from @obj from the @fn
2001 * Returns: The last value returned by @fn, or 0 if there is no child.
2008 * @obj: the object whose children will be navigated
2009 * @fn: the iterator function to be called
2010 * @opaque: an opaque value that will be passed to the iterator
2014 * all the way down to the leaf nodes of the tree. Depth first ordering.
2017 * child nodes) from the @fn callback.
2019 * Returns: The last value returned by @fn, or 0 if there is no child.
2027 * @obj: the parent object
2028 * @name: the name of the parent object's property to add
2032 * Returns: the newly created container object. Its reference count is 1,
2033 * and the reference is owned by the parent object.
2039 * @name: the name of the property
2040 * @type: the type of the property
2041 * @defval: the default value
2042 * @description: description of the property
2044 * Returns: a user-friendly formatted string describing the property