<?xml version="1.0"?>
+<!-- This file was automatically generated from C sources - DO NOT EDIT!
+To affect the contents of this file, edit the original C definitions,
+and/or use gtk-doc annotations. -->
<repository version="1.0"
xmlns="http://www.gtk.org/introspection/core/1.0"
xmlns:c="http://www.gtk.org/introspection/c/1.0"
<include name="GLib" version="2.0"/>
<include name="GObject" version="2.0"/>
<include name="utility" version="1.0"/>
- <namespace name="annotation" version="1.0" shared-library="annotation">
- <callback name="Callback" c:type="AnnotationCallback">
- <return-value transfer-ownership="none">
+ <package name="gobject-2.0"/>
+ <namespace name="annotation"
+ version="1.0"
+ shared-library="libannotation.so"
+ c:prefix="annotation">
+ <callback name="Callback"
+ c:type="AnnotationCallback"
+ doc="This is a callback.">
+ <return-value transfer-ownership="none" doc="array of ints">
<type name="int" c:type="gint*"/>
</return-value>
<parameters>
- <parameter name="in" transfer-ownership="none">
+ <parameter name="in" transfer-ownership="none" doc="array of ints">
<type name="int" c:type="gint*"/>
</parameter>
</parameters>
</callback>
- <callback name="ListCallback" c:type="AnnotationListCallback">
- <return-value transfer-ownership="container">
+ <callback name="ForeachFunc" c:type="AnnotationForeachFunc">
+ <return-value transfer-ownership="none">
+ <type name="none" c:type="void"/>
+ </return-value>
+ <parameters>
+ <parameter name="object" transfer-ownership="none">
+ <type name="Object" c:type="AnnotationObject*"/>
+ </parameter>
+ <parameter name="item" transfer-ownership="none">
+ <type name="utf8" c:type="char*"/>
+ </parameter>
+ <parameter name="user_data" transfer-ownership="none" closure="2">
+ <type name="any" c:type="gpointer"/>
+ </parameter>
+ </parameters>
+ </callback>
+ <callback name="ListCallback"
+ c:type="AnnotationListCallback"
+ doc="This is a callback taking a list.">
+ <return-value transfer-ownership="container" doc="list of strings">
<type name="GLib.List" c:type="GList*">
<type name="utf8"/>
</type>
</return-value>
<parameters>
- <parameter name="in" transfer-ownership="none">
+ <parameter name="in" transfer-ownership="none" doc="list of strings">
<type name="GLib.List" c:type="GList*">
<type name="utf8"/>
</type>
</parameter>
</parameters>
</callback>
+ <callback name="NotifyFunc"
+ c:type="AnnotationNotifyFunc"
+ doc="This is a callback with a 'closure' argument that is not named
+'user_data' and hence has to be annotated.">
+ <return-value transfer-ownership="none">
+ <type name="none" c:type="void"/>
+ </return-value>
+ <parameters>
+ <parameter name="data"
+ transfer-ownership="none"
+ closure="0"
+ doc="The user data">
+ <type name="any" c:type="gpointer"/>
+ </parameter>
+ </parameters>
+ </callback>
<class name="Object"
c:type="AnnotationObject"
+ doc="This is an object used to test annotations."
parent="GObject.Object"
glib:type-name="AnnotationObject"
- glib:get-type="annotation_object_get_type">
+ glib:get-type="annotation_object_get_type"
+ glib:type-struct="ObjectClass">
+ <attribute name="org.example.Test" value="cows"/>
<method name="method" c:identifier="annotation_object_method">
<return-value transfer-ownership="none">
<type name="int" c:type="gint"/>
</return-value>
</method>
- <method name="out" c:identifier="annotation_object_out">
+ <method name="out"
+ c:identifier="annotation_object_out"
+ doc="This is a test for out arguments">
<return-value transfer-ownership="none">
<type name="int" c:type="gint"/>
</return-value>
<parameters>
- <parameter name="outarg" direction="out" transfer-ownership="full">
+ <parameter name="outarg"
+ direction="out"
+ transfer-ownership="full"
+ doc="This is an argument test">
<type name="int" c:type="int*"/>
</parameter>
</parameters>
</method>
<method name="create_object"
- c:identifier="annotation_object_create_object">
- <return-value transfer-ownership="full">
+ c:identifier="annotation_object_create_object"
+ doc="Test returning a caller-owned object">
+ <return-value transfer-ownership="full" doc="The object">
<type name="GObject.Object" c:type="GObject*"/>
</return-value>
</method>
</parameters>
</method>
<method name="notrans" c:identifier="annotation_object_notrans">
- <return-value transfer-ownership="none">
+ <return-value transfer-ownership="none"
+ doc="An object, not referenced">
<type name="GObject.Object" c:type="GObject*"/>
</return-value>
</method>
- <method name="inout" c:identifier="annotation_object_inout">
+ <method name="inout"
+ c:identifier="annotation_object_inout"
+ doc="This is a test for out arguments">
<return-value transfer-ownership="none">
<type name="int" c:type="gint"/>
</return-value>
<parameters>
<parameter name="inoutarg"
direction="inout"
- transfer-ownership="full">
+ transfer-ownership="full"
+ doc="This is an argument test">
<type name="int" c:type="int*"/>
</parameter>
</parameters>
</method>
- <method name="inout2" c:identifier="annotation_object_inout2">
+ <method name="inout2"
+ c:identifier="annotation_object_inout2"
+ doc="This is a second test for out arguments">
<return-value transfer-ownership="none">
<type name="int" c:type="gint"/>
</return-value>
<parameters>
<parameter name="inoutarg"
direction="inout"
- transfer-ownership="full">
+ transfer-ownership="full"
+ doc="This is an argument test">
<type name="int" c:type="int*"/>
</parameter>
</parameters>
</method>
- <method name="inout3" c:identifier="annotation_object_inout3">
+ <method name="inout3"
+ c:identifier="annotation_object_inout3"
+ doc="This is a 3th test for out arguments">
<return-value transfer-ownership="none">
<type name="int" c:type="gint"/>
</return-value>
<parameter name="inoutarg"
direction="inout"
transfer-ownership="full"
- allow-none="1">
+ allow-none="1"
+ doc="This is an argument test">
<type name="int" c:type="int*"/>
</parameter>
</parameters>
</method>
- <method name="in" c:identifier="annotation_object_in">
+ <method name="in"
+ c:identifier="annotation_object_in"
+ doc="This is a test for in arguments">
<return-value transfer-ownership="none">
<type name="int" c:type="gint"/>
</return-value>
<parameters>
- <parameter name="inarg" transfer-ownership="none">
+ <parameter name="inarg"
+ transfer-ownership="none"
+ doc="This is an argument test">
<type name="int" c:type="int*"/>
</parameter>
</parameters>
</method>
- <method name="calleeowns" c:identifier="annotation_object_calleeowns">
+ <method name="calleeowns"
+ c:identifier="annotation_object_calleeowns"
+ doc="This is a test for out arguments; GObject defaults to transfer">
<return-value transfer-ownership="none">
<type name="int" c:type="gint"/>
</return-value>
<parameters>
- <parameter name="toown" direction="out" transfer-ownership="full">
+ <parameter name="toown"
+ direction="out"
+ transfer-ownership="full"
+ doc="a #GObject">
<type name="GObject.Object" c:type="GObject**"/>
</parameter>
</parameters>
</method>
- <method name="calleesowns" c:identifier="annotation_object_calleesowns">
+ <method name="calleesowns"
+ c:identifier="annotation_object_calleesowns"
+ doc="This is a test for out arguments, one transferred, other not">
<return-value transfer-ownership="none">
<type name="int" c:type="gint"/>
</return-value>
<parameters>
- <parameter name="toown1" direction="out" transfer-ownership="full">
+ <parameter name="toown1"
+ direction="out"
+ transfer-ownership="full"
+ doc="a #GObject">
<type name="GObject.Object" c:type="GObject**"/>
</parameter>
- <parameter name="toown2" direction="out" transfer-ownership="none">
+ <parameter name="toown2"
+ direction="out"
+ transfer-ownership="none"
+ doc="a #GObject">
<type name="GObject.Object" c:type="GObject**"/>
</parameter>
</parameters>
</method>
- <method name="get_strings" c:identifier="annotation_object_get_strings">
- <return-value transfer-ownership="full">
+ <method name="get_strings"
+ c:identifier="annotation_object_get_strings"
+ doc="This is a test for returning a list of strings, where
+each string needs to be freed.">
+ <return-value transfer-ownership="full" doc="list of strings">
<type name="GLib.List" c:type="GList*">
<type name="utf8"/>
</type>
</return-value>
</method>
- <method name="get_hash" c:identifier="annotation_object_get_hash">
- <return-value transfer-ownership="full">
+ <method name="get_hash"
+ c:identifier="annotation_object_get_hash"
+ doc="This is a test for returning a hash table mapping strings to
+objects.">
+ <return-value transfer-ownership="full" doc="hash table">
<type name="GLib.HashTable" c:type="GHashTable*">
<type name="utf8"/>
<type name="GObject.Object"/>
</type>
</return-value>
</method>
- <method name="get_objects" c:identifier="annotation_object_get_objects">
- <return-value transfer-ownership="container">
+ <method name="with_voidp" c:identifier="annotation_object_with_voidp">
+ <return-value transfer-ownership="none">
+ <type name="none" c:type="void"/>
+ </return-value>
+ <parameters>
+ <parameter name="data" transfer-ownership="none">
+ <type name="any" c:type="void*"/>
+ </parameter>
+ </parameters>
+ </method>
+ <method name="get_objects"
+ c:identifier="annotation_object_get_objects"
+ doc="This is a test for returning a list of objects.
+The list itself should be freed, but not the internal objects,
+intentionally similar example to gtk_container_get_children">
+ <return-value transfer-ownership="container" doc="list of objects">
<type name="GLib.SList" c:type="GSList*">
<type name="Object"/>
</type>
</parameter>
</parameters>
</method>
- <method name="compute_sum" c:identifier="annotation_object_compute_sum">
+ <method name="compute_sum"
+ c:identifier="annotation_object_compute_sum"
+ doc="Test taking a zero-terminated array">
<return-value transfer-ownership="none">
<type name="none" c:type="void"/>
</return-value>
<parameters>
- <parameter name="nums" transfer-ownership="none">
+ <parameter name="nums"
+ transfer-ownership="none"
+ doc="Sequence of numbers">
<array c:type="int*">
<type name="int"/>
</array>
</parameters>
</method>
<method name="compute_sum_n"
- c:identifier="annotation_object_compute_sum_n">
+ c:identifier="annotation_object_compute_sum_n"
+ doc="Test taking an array with length parameter">
<return-value transfer-ownership="none">
<type name="none" c:type="void"/>
</return-value>
<parameters>
- <parameter name="nums" transfer-ownership="none">
+ <parameter name="nums"
+ transfer-ownership="none"
+ doc="Sequence of numbers">
<array zero-terminated="0" length="2" c:type="int*">
<type name="int"/>
</array>
</parameters>
</method>
<method name="compute_sum_nz"
- c:identifier="annotation_object_compute_sum_nz">
+ c:identifier="annotation_object_compute_sum_nz"
+ doc="Test taking a zero-terminated array with length parameter">
<return-value transfer-ownership="none">
<type name="none" c:type="void"/>
</return-value>
<parameters>
- <parameter name="nums" transfer-ownership="none">
+ <parameter name="nums"
+ transfer-ownership="none"
+ doc="Sequence of numbers">
<array length="2" c:type="int*">
<type name="int"/>
</array>
</parameter>
</parameters>
</method>
- <method name="parse_args" c:identifier="annotation_object_parse_args">
+ <method name="parse_args"
+ c:identifier="annotation_object_parse_args"
+ doc="Test taking a zero-terminated array with length parameter">
<return-value transfer-ownership="none">
<type name="none" c:type="void"/>
</return-value>
<parameters>
- <parameter name="argc" direction="inout" transfer-ownership="full">
+ <parameter name="argc"
+ direction="inout"
+ transfer-ownership="full"
+ doc="Length of the argument vector">
<type name="int" c:type="int*"/>
</parameter>
- <parameter name="argv" direction="inout" transfer-ownership="none">
+ <parameter name="argv"
+ direction="inout"
+ transfer-ownership="full"
+ doc="Argument vector">
<array length="1" c:type="char***">
<type name="utf8"/>
</array>
</parameter>
</parameters>
</method>
- <method name="string_out" c:identifier="annotation_object_string_out">
+ <method name="string_out"
+ c:identifier="annotation_object_string_out"
+ doc="Test returning a string as an out parameter">
<return-value transfer-ownership="none">
<type name="boolean" c:type="gboolean"/>
</return-value>
<parameters>
- <parameter name="str_out" direction="out" transfer-ownership="full">
+ <parameter name="str_out"
+ direction="out"
+ transfer-ownership="full"
+ doc="string return value">
<type name="utf8" c:type="char**"/>
</parameter>
</parameters>
</method>
- <method name="foreach" c:identifier="annotation_object_foreach">
+ <method name="foreach"
+ c:identifier="annotation_object_foreach"
+ doc="Test taking a call-scoped callback">
<return-value transfer-ownership="none">
<type name="none" c:type="void"/>
</return-value>
<parameter name="func"
transfer-ownership="none"
scope="call"
- closure="2">
+ closure="2"
+ doc="Callback to invoke">
<type name="ForeachFunc" c:type="AnnotationForeachFunc"/>
</parameter>
<parameter name="user_data" transfer-ownership="none">
</parameter>
</parameters>
</method>
+ <method name="set_data"
+ c:identifier="annotation_object_set_data"
+ doc="Test taking a guchar * with a length.">
+ <return-value transfer-ownership="none">
+ <type name="none" c:type="void"/>
+ </return-value>
+ <parameters>
+ <parameter name="data" transfer-ownership="none" doc="The data">
+ <array length="2" c:type="guchar*">
+ <type name="uint8"/>
+ </array>
+ </parameter>
+ <parameter name="length" transfer-ownership="none">
+ <type name="size_t" c:type="gsize"/>
+ </parameter>
+ </parameters>
+ </method>
+ <method name="set_data2"
+ c:identifier="annotation_object_set_data2"
+ doc="Test taking a gchar * with a length.">
+ <return-value transfer-ownership="none">
+ <type name="none" c:type="void"/>
+ </return-value>
+ <parameters>
+ <parameter name="data" transfer-ownership="none" doc="The data">
+ <array length="2" c:type="gchar*">
+ <type name="int8"/>
+ </array>
+ </parameter>
+ <parameter name="length" transfer-ownership="none">
+ <type name="size_t" c:type="gsize"/>
+ </parameter>
+ </parameters>
+ </method>
+ <method name="set_data3"
+ c:identifier="annotation_object_set_data3"
+ doc="Test taking a gchar * with a length, overriding the array element
+type.">
+ <return-value transfer-ownership="none">
+ <type name="none" c:type="void"/>
+ </return-value>
+ <parameters>
+ <parameter name="data" transfer-ownership="none" doc="The data">
+ <array length="2" c:type="gpointer">
+ <type name="uint8"/>
+ </array>
+ </parameter>
+ <parameter name="length" transfer-ownership="none">
+ <type name="size_t" c:type="gsize"/>
+ </parameter>
+ </parameters>
+ </method>
<method name="do_not_use"
c:identifier="annotation_object_do_not_use"
deprecated="Use annotation_object_create_object() instead."
<type name="GObject.Object" c:type="GObject*"/>
</return-value>
</method>
+ <method name="watch"
+ c:identifier="annotation_object_watch_full"
+ doc="Test overriding via the "Rename To" annotation.">
+ <return-value transfer-ownership="none">
+ <type name="none" c:type="void"/>
+ </return-value>
+ <parameters>
+ <parameter name="func"
+ transfer-ownership="none"
+ scope="notified"
+ closure="2"
+ destroy="3">
+ <type name="ForeachFunc" c:type="AnnotationForeachFunc"/>
+ </parameter>
+ <parameter name="user_data" transfer-ownership="none">
+ <type name="any" c:type="gpointer"/>
+ </parameter>
+ <parameter name="destroy" transfer-ownership="none" scope="call">
+ <type name="GLib.DestroyNotify" c:type="GDestroyNotify"/>
+ </parameter>
+ </parameters>
+ </method>
+ <method name="extra_annos" c:identifier="annotation_object_extra_annos">
+ <attribute name="org.foobar" value="testvalue"/>
+ <return-value transfer-ownership="none">
+ <type name="none" c:type="void"/>
+ </return-value>
+ </method>
+ <property name="string-property"
+ version="1.0"
+ deprecated="Use better-string-property instead"
+ deprecated-version="1.2"
+ writable="1"
+ construct="1"
+ doc="This is a property which is a string">
+ <type name="utf8" c:type="gchararray"/>
+ </property>
<field name="parent_instance">
<type name="GObject.Object" c:type="GObject"/>
</field>
+ <glib:signal name="doc-empty-arg-parsing"
+ doc="This signal tests an empty document argument (@arg1)">
+ <return-value transfer-ownership="full">
+ <type name="none" c:type="void"/>
+ </return-value>
+ <parameters>
+ <parameter name="arg1" transfer-ownership="none">
+ <type name="any" c:type="gpointer"/>
+ </parameter>
+ </parameters>
+ </glib:signal>
+ <glib:signal name="list-signal"
+ doc="This is a signal which takes a list of strings, but it's not
+known by GObject as it's only marked as G_TYPE_POINTER">
+ <return-value transfer-ownership="full">
+ <type name="none" c:type="void"/>
+ </return-value>
+ <parameters>
+ <parameter name="list"
+ transfer-ownership="container"
+ doc="a list of strings">
+ <type name="GLib.List" c:type="gpointer">
+ <type name="utf8"/>
+ </type>
+ </parameter>
+ </parameters>
+ </glib:signal>
+ <glib:signal name="string-signal"
+ doc="This is a signal which has a broken signal handler,
+it says it's pointer but it's actually a string."
+ version="1.0"
+ deprecated="Use other-signal instead"
+ deprecated-version="1.2">
+ <return-value transfer-ownership="full">
+ <type name="none" c:type="void"/>
+ </return-value>
+ <parameters>
+ <parameter name="string" transfer-ownership="none" doc="a string">
+ <type name="utf8" c:type="gpointer"/>
+ </parameter>
+ </parameters>
+ </glib:signal>
</class>
- <record name="ObjectClass" c:type="AnnotationObjectClass">
+ <record name="ObjectClass"
+ c:type="AnnotationObjectClass"
+ glib:is-gtype-struct-for="Object">
<field name="parent_class">
<type name="GObject.ObjectClass" c:type="GObjectClass"/>
</field>
</record>
- <callback name="ForeachFunc" c:type="AnnotationForeachFunc">
+ <record name="Struct"
+ c:type="AnnotationStruct"
+ doc="This is a test of an array of object in an field of a struct.">
+ <field name="objects" writable="1">
+ <array zero-terminated="0" c:type="AnnotationObject*" fixed-size="10">
+ <type name="Object"/>
+ </array>
+ </field>
+ </record>
+ <function name="custom_destroy"
+ c:identifier="annotation_custom_destroy"
+ doc="Test messing up the heuristic of closure/destroy-notification
+detection, and fixing it via annotations.">
<return-value transfer-ownership="none">
<type name="none" c:type="void"/>
</return-value>
<parameters>
- <parameter name="object" transfer-ownership="none">
- <type name="Object" c:type="AnnotationObject*"/>
+ <parameter name="callback"
+ transfer-ownership="none"
+ scope="call"
+ closure="2"
+ destroy="1"
+ doc="Destroy notification">
+ <type name="Callback" c:type="AnnotationCallback"/>
</parameter>
- <parameter name="item" transfer-ownership="none">
- <type name="utf8" c:type="char*"/>
+ <parameter name="destroy" transfer-ownership="none" scope="call">
+ <type name="NotifyFunc" c:type="AnnotationNotifyFunc"/>
</parameter>
- <parameter name="user_data" transfer-ownership="none">
+ <parameter name="data" transfer-ownership="none">
<type name="any" c:type="gpointer"/>
</parameter>
</parameters>
- </callback>
+ </function>
+ <function name="get_source_file" c:identifier="annotation_get_source_file">
+ <return-value transfer-ownership="full" doc="Source file">
+ <type name="filename" c:type="char*"/>
+ </return-value>
+ </function>
<function name="init" c:identifier="annotation_init">
<return-value transfer-ownership="none">
<type name="none" c:type="void"/>
</return-value>
<parameters>
- <parameter name="argc" direction="inout" transfer-ownership="full">
+ <parameter name="argc"
+ direction="inout"
+ transfer-ownership="full"
+ doc="The number of args.">
<type name="int" c:type="int*"/>
</parameter>
- <parameter name="argv" direction="inout" transfer-ownership="none">
+ <parameter name="argv"
+ direction="inout"
+ transfer-ownership="full"
+ doc="The arguments.">
<array length="0" c:type="char***">
<type name="utf8"/>
</array>
</parameters>
</function>
<function name="return_array" c:identifier="annotation_return_array">
- <return-value transfer-ownership="none">
+ <return-value transfer-ownership="full" doc="The return value">
<array length="0" c:type="char**">
<type name="utf8"/>
</array>
</return-value>
<parameters>
- <parameter name="length" direction="out" transfer-ownership="full">
+ <parameter name="length"
+ direction="out"
+ transfer-ownership="full"
+ doc="Number of return values">
<type name="int" c:type="int*"/>
</parameter>
</parameters>
</function>
+ <function name="set_source_file" c:identifier="annotation_set_source_file">
+ <return-value transfer-ownership="none">
+ <type name="none" c:type="void"/>
+ </return-value>
+ <parameters>
+ <parameter name="fname" transfer-ownership="none" doc="Source file">
+ <type name="filename" c:type="char*"/>
+ </parameter>
+ </parameters>
+ </function>
+ <function name="string_array_length"
+ c:identifier="annotation_string_array_length">
+ <return-value transfer-ownership="none">
+ <type name="none" c:type="void"/>
+ </return-value>
+ <parameters>
+ <parameter name="n_properties" transfer-ownership="none">
+ <type name="uint" c:type="guint"/>
+ </parameter>
+ <parameter name="properties" transfer-ownership="none">
+ <array length="0" c:type="gchar*">
+ <type name="utf8"/>
+ </array>
+ </parameter>
+ </parameters>
+ </function>
+ <function name="string_zero_terminated"
+ c:identifier="annotation_string_zero_terminated">
+ <return-value transfer-ownership="full" doc="The return value">
+ <array c:type="char**">
+ <type name="utf8"/>
+ </array>
+ </return-value>
+ </function>
+ <function name="string_zero_terminated_out"
+ c:identifier="annotation_string_zero_terminated_out">
+ <return-value transfer-ownership="none">
+ <type name="none" c:type="void"/>
+ </return-value>
+ <parameters>
+ <parameter name="out" direction="inout" transfer-ownership="full">
+ <array c:type="char***">
+ <type name="utf8"/>
+ </array>
+ </parameter>
+ </parameters>
+ </function>
<function name="versioned"
c:identifier="annotation_versioned"
version="0.6">
<type name="none" c:type="void"/>
</return-value>
</function>
- <record name="Struct" c:type="_AnnotationStruct">
- <field name="objects" writable="1">
- <array zero-terminated="0" c:type="AnnotationObject*" fixed-size="10">
- <type name="Object"/>
- </array>
- </field>
- </record>
</namespace>
</repository>