1 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
4 <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
5 <title>gtypelib</title>
6 <meta name="generator" content="DocBook XSL Stylesheets V1.76.1">
7 <link rel="home" href="index.html" title="GObject Introspection Reference Manual">
8 <link rel="up" href="gi-typelib.html" title="Typelib binary format">
9 <link rel="prev" href="gi-typelib.html" title="Typelib binary format">
10 <link rel="next" href="annotation-glossary.html" title="Annotation Glossary">
11 <meta name="generator" content="GTK-Doc V1.18.1 (XML mode)">
12 <link rel="stylesheet" href="style.css" type="text/css">
14 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
15 <table class="navigation" id="top" width="100%" summary="Navigation header" cellpadding="2" cellspacing="2">
17 <td><a accesskey="p" href="gi-typelib.html"><img src="left.png" width="24" height="24" border="0" alt="Prev"></a></td>
18 <td><a accesskey="u" href="gi-typelib.html"><img src="up.png" width="24" height="24" border="0" alt="Up"></a></td>
19 <td><a accesskey="h" href="index.html"><img src="home.png" width="24" height="24" border="0" alt="Home"></a></td>
20 <th width="100%" align="center">GObject Introspection Reference Manual</th>
21 <td><a accesskey="n" href="annotation-glossary.html"><img src="right.png" width="24" height="24" border="0" alt="Next"></a></td>
23 <tr><td colspan="5" class="shortcuts">
24 <a href="#gi-gtypelib.synopsis" class="shortcut">Top</a>
26 <a href="#gi-gtypelib.description" class="shortcut">Description</a>
29 <div class="refentry">
30 <a name="gi-gtypelib"></a><div class="titlepage"></div>
31 <div class="refnamediv"><table width="100%"><tr>
33 <h2><span class="refentrytitle"><a name="gi-gtypelib.top_of_page"></a>gtypelib</span></h2>
34 <p>gtypelib — Layout and accessors for typelib</p>
36 <td valign="top" align="right"></td>
38 <div class="refsect1">
39 <a name="gi-gtypelib.stability-level"></a><h2>Stability Level</h2>
40 Stable, unless otherwise indicated
42 <div class="refsynopsisdiv">
43 <a name="gi-gtypelib.synopsis"></a><h2>Synopsis</h2>
44 <pre class="synopsis">#define <a class="link" href="gi-gtypelib.html#G-IR-MAGIC:CAPS" title="G_IR_MAGIC">G_IR_MAGIC</a>
45 enum <a class="link" href="gi-gtypelib.html#GTypelibBlobType" title="enum GTypelibBlobType">GTypelibBlobType</a>;
46 <a class="link" href="gi-gtypelib.html#Header" title="Header">Header</a>;
47 <a class="link" href="gi-gtypelib.html#DirEntry" title="DirEntry">DirEntry</a>;
48 <a class="link" href="gi-gtypelib.html#ArgBlob" title="ArgBlob">ArgBlob</a>;
49 <a class="link" href="gi-gtypelib.html#SignatureBlob" title="SignatureBlob">SignatureBlob</a>;
50 <a class="link" href="gi-gtypelib.html#CommonBlob" title="CommonBlob">CommonBlob</a>;
51 <a class="link" href="gi-gtypelib.html#FunctionBlob" title="FunctionBlob">FunctionBlob</a>;
52 <a class="link" href="gi-gtypelib.html#CallbackBlob" title="CallbackBlob">CallbackBlob</a>;
53 <a class="link" href="gi-gtypelib.html#InterfaceTypeBlob" title="InterfaceTypeBlob">InterfaceTypeBlob</a>;
54 <a class="link" href="gi-gtypelib.html#ParamTypeBlob" title="ParamTypeBlob">ParamTypeBlob</a>;
55 <a class="link" href="gi-gtypelib.html#ErrorTypeBlob" title="ErrorTypeBlob">ErrorTypeBlob</a>;
56 <a class="link" href="gi-gtypelib.html#ValueBlob" title="ValueBlob">ValueBlob</a>;
57 <a class="link" href="gi-gtypelib.html#FieldBlob" title="FieldBlob">FieldBlob</a>;
58 <a class="link" href="gi-gtypelib.html#RegisteredTypeBlob" title="RegisteredTypeBlob">RegisteredTypeBlob</a>;
59 <a class="link" href="gi-gtypelib.html#StructBlob" title="StructBlob">StructBlob</a>;
60 <a class="link" href="gi-gtypelib.html#UnionBlob" title="UnionBlob">UnionBlob</a>;
61 <a class="link" href="gi-gtypelib.html#EnumBlob" title="EnumBlob">EnumBlob</a>;
62 <a class="link" href="gi-gtypelib.html#PropertyBlob" title="PropertyBlob">PropertyBlob</a>;
63 <a class="link" href="gi-gtypelib.html#SignalBlob" title="SignalBlob">SignalBlob</a>;
64 <a class="link" href="gi-gtypelib.html#VFuncBlob" title="VFuncBlob">VFuncBlob</a>;
65 <a class="link" href="gi-gtypelib.html#ObjectBlob" title="ObjectBlob">ObjectBlob</a>;
66 <a class="link" href="gi-gtypelib.html#InterfaceBlob" title="InterfaceBlob">InterfaceBlob</a>;
67 <a class="link" href="gi-gtypelib.html#ConstantBlob" title="ConstantBlob">ConstantBlob</a>;
68 <a class="link" href="gi-gtypelib.html#AttributeBlob" title="AttributeBlob">AttributeBlob</a>;
69 <a class="link" href="gi-gtypelib.html#DirEntry" title="DirEntry"><span class="returnvalue">DirEntry</span></a> * <a class="link" href="gi-gtypelib.html#g-typelib-get-dir-entry" title="g_typelib_get_dir_entry ()">g_typelib_get_dir_entry</a> (<em class="parameter"><code><a class="link" href="gi-girepository.html#GITypelib" title="GITypelib"><span class="type">GITypelib</span></a> *typelib</code></em>,
70 <em class="parameter"><code><span class="type">guint16</span> index</code></em>);
71 <span class="returnvalue">void</span> <a class="link" href="gi-gtypelib.html#g-typelib-check-sanity" title="g_typelib_check_sanity ()">g_typelib_check_sanity</a> (<em class="parameter"><code><span class="type">void</span></code></em>);
72 #define <a class="link" href="gi-gtypelib.html#g-typelib-get-string" title="g_typelib_get_string()">g_typelib_get_string</a> (typelib,
74 #define <a class="link" href="gi-gtypelib.html#G-TYPELIB-ERROR:CAPS" title="G_TYPELIB_ERROR">G_TYPELIB_ERROR</a>
75 <span class="returnvalue">gboolean</span> <a class="link" href="gi-gtypelib.html#g-typelib-validate" title="g_typelib_validate ()">g_typelib_validate</a> (<em class="parameter"><code><a class="link" href="gi-girepository.html#GITypelib" title="GITypelib"><span class="type">GITypelib</span></a> *typelib</code></em>,
76 <em class="parameter"><code><span class="type">GError</span> **error</code></em>);
77 #define <a class="link" href="gi-gtypelib.html#BLOB-IS-REGISTERED-TYPE:CAPS" title="BLOB_IS_REGISTERED_TYPE()">BLOB_IS_REGISTERED_TYPE</a> (blob)
80 <div class="refsect1">
81 <a name="gi-gtypelib.description"></a><h2>Description</h2>
83 The "typelib" is a binary, readonly, memory-mappable database
84 containing reflective information about a GObject library.
87 The format of GObject typelib is strongly influenced by the Mozilla XPCOM
91 Some of the differences to XPCOM include:
93 <div class="itemizedlist"><ul class="itemizedlist" type="disc">
94 <li class="listitem"><p>Type information is stored not quite as compactly (XPCOM stores it inline
95 in function descriptions in variable-sized blobs of 1 to n bytes. We store
96 16 bits of type information for each parameter, which is enough to encode
97 simple types inline. Complex (e.g. recursive) types are stored out of line
98 in a separate list of types.</p></li>
99 <li class="listitem"><p>String and complex type data is stored outside of typelib entry blobs,
100 references are stored as offsets relative to the start of the typelib.
101 One possibility is to store the strings and types in a pools at the end
102 of the typelib.</p></li>
107 The typelib has the following general format.
110 typelib ::= header, section-index, directory, blobs, attributes, attributedata
113 directory ::= list of entries
116 entry ::= blob type, name, namespace, offset
117 blob ::= function|callback|struct|boxed|enum|flags|object|interface|constant|union
118 attributes ::= list of attributes, sorted by offset
119 attribute ::= offset, key, value
120 attributedata ::= string data for attributes
126 We describe the fragments that make up the typelib in the form of C structs
127 (although some fall short of being valid C structs since they contain multiple
131 <div class="refsect1">
132 <a name="gi-gtypelib.details"></a><h2>Details</h2>
133 <div class="refsect2">
134 <a name="G-IR-MAGIC:CAPS"></a><h3>G_IR_MAGIC</h3>
135 <pre class="programlisting">#define G_IR_MAGIC "GOBJ\nMETADATA\r\n\032"
138 Identifying prefix for the typelib. This was inspired by XPCOM,
139 which in turn borrowed from PNG.
143 <div class="refsect2">
144 <a name="GTypelibBlobType"></a><h3>enum GTypelibBlobType</h3>
145 <pre class="programlisting">typedef enum {
156 BLOB_TYPE_INVALID_0, /* DELETED - used to be ErrorDomain */
161 The integral value of this enumeration appears in each "Blob"
162 component of a typelib to identify its type.
164 <div class="variablelist"><table border="0">
165 <col align="left" valign="top">
168 <td><p><a name="BLOB-TYPE-INVALID:CAPS"></a><span class="term"><code class="literal">BLOB_TYPE_INVALID</code></span></p></td>
169 <td>Should not appear in code
173 <td><p><a name="BLOB-TYPE-FUNCTION:CAPS"></a><span class="term"><code class="literal">BLOB_TYPE_FUNCTION</code></span></p></td>
174 <td>A <a class="link" href="gi-gtypelib.html#FunctionBlob" title="FunctionBlob"><span class="type">FunctionBlob</span></a>
178 <td><p><a name="BLOB-TYPE-CALLBACK:CAPS"></a><span class="term"><code class="literal">BLOB_TYPE_CALLBACK</code></span></p></td>
179 <td>A <a class="link" href="gi-gtypelib.html#CallbackBlob" title="CallbackBlob"><span class="type">CallbackBlob</span></a>
183 <td><p><a name="BLOB-TYPE-STRUCT:CAPS"></a><span class="term"><code class="literal">BLOB_TYPE_STRUCT</code></span></p></td>
184 <td>A <a class="link" href="gi-gtypelib.html#StructBlob" title="StructBlob"><span class="type">StructBlob</span></a>
188 <td><p><a name="BLOB-TYPE-BOXED:CAPS"></a><span class="term"><code class="literal">BLOB_TYPE_BOXED</code></span></p></td>
189 <td>Can be either a <a class="link" href="gi-gtypelib.html#StructBlob" title="StructBlob"><span class="type">StructBlob</span></a> or <a class="link" href="gi-gtypelib.html#UnionBlob" title="UnionBlob"><span class="type">UnionBlob</span></a>
193 <td><p><a name="BLOB-TYPE-ENUM:CAPS"></a><span class="term"><code class="literal">BLOB_TYPE_ENUM</code></span></p></td>
194 <td>An <a class="link" href="gi-gtypelib.html#EnumBlob" title="EnumBlob"><span class="type">EnumBlob</span></a>
198 <td><p><a name="BLOB-TYPE-FLAGS:CAPS"></a><span class="term"><code class="literal">BLOB_TYPE_FLAGS</code></span></p></td>
199 <td>An <a class="link" href="gi-gtypelib.html#EnumBlob" title="EnumBlob"><span class="type">EnumBlob</span></a>
203 <td><p><a name="BLOB-TYPE-OBJECT:CAPS"></a><span class="term"><code class="literal">BLOB_TYPE_OBJECT</code></span></p></td>
204 <td>An <a class="link" href="gi-gtypelib.html#ObjectBlob" title="ObjectBlob"><span class="type">ObjectBlob</span></a>
208 <td><p><a name="BLOB-TYPE-INTERFACE:CAPS"></a><span class="term"><code class="literal">BLOB_TYPE_INTERFACE</code></span></p></td>
209 <td>An <a class="link" href="gi-gtypelib.html#InterfaceBlob" title="InterfaceBlob"><span class="type">InterfaceBlob</span></a>
213 <td><p><a name="BLOB-TYPE-CONSTANT:CAPS"></a><span class="term"><code class="literal">BLOB_TYPE_CONSTANT</code></span></p></td>
214 <td>A <a class="link" href="gi-gtypelib.html#ConstantBlob" title="ConstantBlob"><span class="type">ConstantBlob</span></a>
218 <td><p><a name="BLOB-TYPE-INVALID-0:CAPS"></a><span class="term"><code class="literal">BLOB_TYPE_INVALID_0</code></span></p></td>
222 <td><p><a name="BLOB-TYPE-UNION:CAPS"></a><span class="term"><code class="literal">BLOB_TYPE_UNION</code></span></p></td>
223 <td>A <a class="link" href="gi-gtypelib.html#UnionBlob" title="UnionBlob"><span class="type">UnionBlob</span></a>
230 <div class="refsect2">
231 <a name="Header"></a><h3>Header</h3>
232 <pre class="programlisting">typedef struct {
234 guint8 major_version;
235 guint8 minor_version;
237 guint16 n_local_entries;
239 guint32 n_attributes;
242 guint32 dependencies;
247 guint32 shared_library;
250 guint16 entry_blob_size;
251 guint16 function_blob_size;
252 guint16 callback_blob_size;
253 guint16 signal_blob_size;
254 guint16 vfunc_blob_size;
255 guint16 arg_blob_size;
256 guint16 property_blob_size;
257 guint16 field_blob_size;
258 guint16 value_blob_size;
259 guint16 attribute_blob_size;
260 guint16 constant_blob_size;
261 guint16 error_domain_blob_size;
263 guint16 signature_blob_size;
264 guint16 enum_blob_size;
265 guint16 struct_blob_size;
266 guint16 object_blob_size;
267 guint16 interface_blob_size;
268 guint16 union_blob_size;
274 The header structure appears exactly once at the beginning of a typelib. It is a
275 collection of meta-information, such as the number of entries and dependencies.
277 <div class="variablelist"><table border="0">
278 <col align="left" valign="top">
281 <td><p><span class="term"><span class="type">gchar</span> <em class="structfield"><code><a name="Header.magic"></a>magic</code></em>[16];</span></p></td>
282 <td>See <a class="link" href="gi-gtypelib.html#G-IR-MAGIC:CAPS" title="G_IR_MAGIC"><span class="type">G_IR_MAGIC</span></a>.</td>
285 <td><p><span class="term"><span class="type">guint8</span> <em class="structfield"><code><a name="Header.major-version"></a>major_version</code></em>;</span></p></td>
286 <td>The version of the typelib format. Minor version changes indicate
287 compatible changes and should still allow the typelib to be parsed
288 by a parser designed for the same major_version.</td>
291 <td><p><span class="term"><span class="type">guint8</span> <em class="structfield"><code><a name="Header.minor-version"></a>minor_version</code></em>;</span></p></td>
292 <td>See major_version.</td>
295 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="Header.n-entries"></a>n_entries</code></em>;</span></p></td>
296 <td>The number of entries in the directory.</td>
299 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="Header.n-local-entries"></a>n_local_entries</code></em>;</span></p></td>
300 <td>The number of entries referring to blobs in this typelib. The
301 local entries must occur before the unresolved entries.</td>
304 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="Header.directory"></a>directory</code></em>;</span></p></td>
305 <td>Offset of the directory in the typelib.</td>
308 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="Header.n-attributes"></a>n_attributes</code></em>;</span></p></td>
309 <td>Number of attribute blocks</td>
312 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="Header.attributes"></a>attributes</code></em>;</span></p></td>
313 <td>Offset of the list of attributes in the typelib.</td>
316 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="Header.dependencies"></a>dependencies</code></em>;</span></p></td>
317 <td>Offset of a single string, which is the list of
318 dependencies, separated by the '|' character. The
319 dependencies are required in order to avoid having programs
320 consuming a typelib check for an "Unresolved" type return
321 from every API call.</td>
324 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="Header.size"></a>size</code></em>;</span></p></td>
325 <td>The size in bytes of the typelib.</td>
328 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="Header.namespace"></a>namespace</code></em>;</span></p></td>
329 <td>Offset of the namespace string in the typelib.</td>
332 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="Header.nsversion"></a>nsversion</code></em>;</span></p></td>
333 <td>Offset of the namespace version string in the typelib.</td>
336 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="Header.shared-library"></a>shared_library</code></em>;</span></p></td>
337 <td>This field is the set of shared libraries associated
338 with the typelib. The entries are separated by the '|' (pipe) character.</td>
341 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="Header.c-prefix"></a>c_prefix</code></em>;</span></p></td>
342 <td>The prefix for the function names of the library</td>
345 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="Header.entry-blob-size"></a>entry_blob_size</code></em>;</span></p></td>
346 <td>The sizes of fixed-size blobs. Recording this information here
347 allows to write parser which continue to work if the format is
348 extended by adding new fields to the end of the fixed-size blobs.</td>
351 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="Header.function-blob-size"></a>function_blob_size</code></em>;</span></p></td>
355 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="Header.callback-blob-size"></a>callback_blob_size</code></em>;</span></p></td>
359 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="Header.signal-blob-size"></a>signal_blob_size</code></em>;</span></p></td>
363 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="Header.vfunc-blob-size"></a>vfunc_blob_size</code></em>;</span></p></td>
367 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="Header.arg-blob-size"></a>arg_blob_size</code></em>;</span></p></td>
371 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="Header.property-blob-size"></a>property_blob_size</code></em>;</span></p></td>
375 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="Header.field-blob-size"></a>field_blob_size</code></em>;</span></p></td>
379 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="Header.value-blob-size"></a>value_blob_size</code></em>;</span></p></td>
383 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="Header.attribute-blob-size"></a>attribute_blob_size</code></em>;</span></p></td>
387 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="Header.constant-blob-size"></a>constant_blob_size</code></em>;</span></p></td>
391 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="Header.error-domain-blob-size"></a>error_domain_blob_size</code></em>;</span></p></td>
395 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="Header.signature-blob-size"></a>signature_blob_size</code></em>;</span></p></td>
399 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="Header.enum-blob-size"></a>enum_blob_size</code></em>;</span></p></td>
403 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="Header.struct-blob-size"></a>struct_blob_size</code></em>;</span></p></td>
407 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="Header.object-blob-size"></a>object_blob_size</code></em>;</span></p></td>
411 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="Header.interface-blob-size"></a>interface_blob_size</code></em>;</span></p></td>
412 <td>For variable-size blobs, the size of the struct up to the first
413 flexible array member. Recording this information here allows to
414 write parser which continue to work if the format is extended by
415 adding new fields before the first flexible array member in
416 variable-size blobs.</td>
419 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="Header.union-blob-size"></a>union_blob_size</code></em>;</span></p></td>
423 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="Header.sections"></a>sections</code></em>;</span></p></td>
424 <td>Offset of section blob array</td>
430 <div class="refsect2">
431 <a name="DirEntry"></a><h3>DirEntry</h3>
432 <pre class="programlisting">typedef struct {
441 References to directory entries are stored as 1-based 16-bit indexes.
444 All blobs pointed to by a directory entry start with the same layout for
445 the first 8 bytes (the reserved flags may be used by some blob types)
447 <div class="variablelist"><table border="0">
448 <col align="left" valign="top">
451 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="DirEntry.blob-type"></a>blob_type</code></em>;</span></p></td>
452 <td>A <a class="link" href="gi-gtypelib.html#GTypelibBlobType" title="enum GTypelibBlobType"><span class="type">GTypelibBlobType</span></a>
456 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="DirEntry.local"></a>local</code></em> : 1;</span></p></td>
457 <td>Whether this entry refers to a blob in this typelib.</td>
460 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="DirEntry.name"></a>name</code></em>;</span></p></td>
461 <td>The name of the entry.</td>
464 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="DirEntry.offset"></a>offset</code></em>;</span></p></td>
465 <td>If is_local is set, this is the offset of the blob in the typelib.
466 Otherwise, it is the offset of the namespace in which the blob has
467 to be looked up by name.</td>
473 <div class="refsect2">
474 <a name="ArgBlob"></a><h3>ArgBlob</h3>
475 <pre class="programlisting">typedef struct {
480 guint caller_allocates : 1;
481 guint allow_none : 1;
483 guint transfer_ownership : 1;
484 guint transfer_container_ownership : 1;
485 guint return_value : 1;
492 SimpleTypeBlob arg_type;
496 Types are specified by four bytes. If the three high bytes are zero,
497 the low byte describes a basic type, otherwise the 32bit number is an
498 offset which points to a TypeBlob.
500 <div class="variablelist"><table border="0">
501 <col align="left" valign="top">
504 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="ArgBlob.name"></a>name</code></em>;</span></p></td>
505 <td>A suggested name for the parameter.</td>
508 <td><p><span class="term"><span class="type">guint</span> <em class="structfield"><code><a name="ArgBlob.in"></a>in</code></em> : 1;</span></p></td>
509 <td>The parameter is an input to the function</td>
512 <td><p><span class="term"><span class="type">guint</span> <em class="structfield"><code><a name="ArgBlob.out"></a>out</code></em> : 1;</span></p></td>
513 <td>The parameter is used to return an output of the function.
514 Parameters can be both in and out. Out parameters implicitly
515 add another level of indirection to the parameter type. Ie if
516 the type is uint32 in an out parameter, the function actually
517 takes an uint32*.</td>
520 <td><p><span class="term"><span class="type">guint</span> <em class="structfield"><code><a name="ArgBlob.caller-allocates"></a>caller_allocates</code></em> : 1;</span></p></td>
521 <td>The parameter is a pointer to a struct or object that will
522 receive an output of the function.</td>
525 <td><p><span class="term"><span class="type">guint</span> <em class="structfield"><code><a name="ArgBlob.allow-none"></a>allow_none</code></em> : 1;</span></p></td>
526 <td>Only meaningful for types which are passed as pointers.
527 For an in parameter, indicates if it is ok to pass NULL in, for
528 an out parameter, whether it may return NULL. Note that NULL is a
529 valid GList and GSList value, thus allow_none will normally be set
530 for parameters of these types.</td>
533 <td><p><span class="term"><span class="type">guint</span> <em class="structfield"><code><a name="ArgBlob.optional"></a>optional</code></em> : 1;</span></p></td>
534 <td>For an out parameter, indicates that NULL may be passed in
535 if the value is not needed.</td>
538 <td><p><span class="term"><span class="type">guint</span> <em class="structfield"><code><a name="ArgBlob.transfer-ownership"></a>transfer_ownership</code></em> : 1;</span></p></td>
539 <td>For an in parameter, indicates that the function takes over
540 ownership of the parameter value. For an out parameter, it
541 indicates that the caller is responsible for freeing the return
545 <td><p><span class="term"><span class="type">guint</span> <em class="structfield"><code><a name="ArgBlob.transfer-container-ownership"></a>transfer_container_ownership</code></em> : 1;</span></p></td>
546 <td>For container types, indicates that the
547 ownership of the container, but not of its contents is transferred. This is typically the case
548 for out parameters returning lists of statically allocated things.</td>
551 <td><p><span class="term"><span class="type">guint</span> <em class="structfield"><code><a name="ArgBlob.return-value"></a>return_value</code></em> : 1;</span></p></td>
552 <td>The parameter should be considered the return value of the function.
553 Only out parameters can be marked as return value, and there can be
554 at most one per function call. If an out parameter is marked as
555 return value, the actual return value of the function should be
556 either void or a boolean indicating the success of the call.</td>
559 <td><p><span class="term"><span class="type">guint</span> <em class="structfield"><code><a name="ArgBlob.scope"></a>scope</code></em> : 3;</span></p></td>
560 <td>A <a class="link" href="gi-GIArgInfo.html#GIScopeType" title="enum GIScopeType"><span class="type">GIScopeType</span></a>. If the parameter is of a callback type, this denotes the scope
561 of the user_data and the callback function pointer itself
562 (for languages that emit code at run-time).</td>
565 <td><p><span class="term"><span class="type">guint</span> <em class="structfield"><code><a name="ArgBlob.skip"></a>skip</code></em> : 1;</span></p></td>
566 <td>Indicates that the parameter is only useful in C and should be skipped.</td>
569 <td><p><span class="term"><span class="type">gint8</span> <em class="structfield"><code><a name="ArgBlob.closure"></a>closure</code></em>;</span></p></td>
570 <td>Index of the closure (user_data) parameter associated with the callback,
574 <td><p><span class="term"><span class="type">gint8</span> <em class="structfield"><code><a name="ArgBlob.destroy"></a>destroy</code></em>;</span></p></td>
575 <td>Index of the destroy notfication callback parameter associated with
576 the callback, or -1.</td>
579 <td><p><span class="term"><span class="type">SimpleTypeBlob</span> <em class="structfield"><code><a name="ArgBlob.arg-type"></a>arg_type</code></em>;</span></p></td>
580 <td>Describes the type of the parameter. See details below.</td>
586 <div class="refsect2">
587 <a name="SignatureBlob"></a><h3>SignatureBlob</h3>
588 <pre class="programlisting">typedef struct {
589 SimpleTypeBlob return_type;
591 guint16 may_return_null : 1;
592 guint16 caller_owns_return_value : 1;
593 guint16 caller_owns_return_container : 1;
594 guint16 skip_return : 1;
595 guint16 reserved :12;
602 <div class="variablelist"><table border="0">
603 <col align="left" valign="top">
606 <td><p><span class="term"><span class="type">SimpleTypeBlob</span> <em class="structfield"><code><a name="SignatureBlob.return-type"></a>return_type</code></em>;</span></p></td>
607 <td>Describes the type of the return value. See details below.</td>
610 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="SignatureBlob.may-return-null"></a>may_return_null</code></em> : 1;</span></p></td>
611 <td>Only relevant for pointer types. Indicates whether the caller
612 must expect NULL as a return value.</td>
615 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="SignatureBlob.caller-owns-return-value"></a>caller_owns_return_value</code></em> : 1;</span></p></td>
616 <td>If set, the caller is responsible for freeing the return value
617 if it is no longer needed.</td>
620 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="SignatureBlob.caller-owns-return-container"></a>caller_owns_return_container</code></em> : 1;</span></p></td>
621 <td>This flag is only relevant if the return type is a container type.
622 If the flag is set, the caller is resonsible for freeing the
623 container, but not its contents.</td>
626 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="SignatureBlob.skip-return"></a>skip_return</code></em> : 1;</span></p></td>
627 <td>Indicates that the return value is only useful in C and should be skipped.</td>
630 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="SignatureBlob.reserved"></a>reserved</code></em> :12;</span></p></td>
634 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="SignatureBlob.n-arguments"></a>n_arguments</code></em>;</span></p></td>
635 <td>The number of arguments that this function expects, also the length
636 of the array of ArgBlobs.</td>
639 <td><p><span class="term"><a class="link" href="gi-gtypelib.html#ArgBlob" title="ArgBlob"><span class="type">ArgBlob</span></a> <em class="structfield"><code><a name="SignatureBlob.arguments"></a>arguments</code></em>[];</span></p></td>
640 <td>An array of ArgBlob for the arguments of the function.</td>
646 <div class="refsect2">
647 <a name="CommonBlob"></a><h3>CommonBlob</h3>
648 <pre class="programlisting">typedef struct {
649 guint16 blob_type; /* 1 */
651 guint16 deprecated : 1;
656 The <a class="link" href="gi-gtypelib.html#CommonBlob" title="CommonBlob"><span class="type">CommonBlob</span></a> is shared between <a class="link" href="gi-gtypelib.html#FunctionBlob" title="FunctionBlob"><span class="type">FunctionBlob</span></a>,
657 <a class="link" href="gi-gtypelib.html#CallbackBlob" title="CallbackBlob"><span class="type">CallbackBlob</span></a>, <a class="link" href="gi-gtypelib.html#SignalBlob" title="SignalBlob"><span class="type">SignalBlob</span></a>.
659 <div class="variablelist"><table border="0">
660 <col align="left" valign="top">
663 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="CommonBlob.blob-type"></a>blob_type</code></em>;</span></p></td>
664 <td>A <a class="link" href="gi-gtypelib.html#GTypelibBlobType" title="enum GTypelibBlobType"><span class="type">GTypelibBlobType</span></a>
668 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="CommonBlob.deprecated"></a>deprecated</code></em> : 1;</span></p></td>
669 <td>Whether the blob is deprecated.</td>
672 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="CommonBlob.name"></a>name</code></em>;</span></p></td>
673 <td>The name of the blob.</td>
679 <div class="refsect2">
680 <a name="FunctionBlob"></a><h3>FunctionBlob</h3>
681 <pre class="programlisting">typedef struct {
682 guint16 blob_type; /* 1 */
684 guint16 deprecated : 1;
687 guint16 constructor : 1;
688 guint16 wraps_vfunc : 1;
691 /* Note the bits above need to match CommonBlob
692 * and are thus exhausted, extend things using
693 * the reserved block below. */
699 guint16 is_static : 1;
700 guint16 reserved : 15;
701 guint16 reserved2 : 16;
704 <div class="variablelist"><table border="0">
705 <col align="left" valign="top">
708 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="FunctionBlob.blob-type"></a>blob_type</code></em>;</span></p></td>
712 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="FunctionBlob.deprecated"></a>deprecated</code></em> : 1;</span></p></td>
713 <td>The function is deprecated.</td>
716 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="FunctionBlob.setter"></a>setter</code></em> : 1;</span></p></td>
717 <td>The function is a setter for a property. Language bindings may
718 prefer to not bind individual setters and rely on the generic
719 <code class="function">g_object_set()</code>.</td>
722 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="FunctionBlob.getter"></a>getter</code></em> : 1;</span></p></td>
723 <td>The function is a getter for a property. Language bindings may
724 prefer to not bind individual getters and rely on the generic
725 <code class="function">g_object_get()</code>.</td>
728 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="FunctionBlob.constructor"></a>constructor</code></em> : 1;</span></p></td>
729 <td>The function acts as a constructor for the object it is contained
733 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="FunctionBlob.wraps-vfunc"></a>wraps_vfunc</code></em> : 1;</span></p></td>
734 <td>The function is a simple wrapper for a virtual function.</td>
737 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="FunctionBlob.throws"></a>throws</code></em> : 1;</span></p></td>
741 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="FunctionBlob.index"></a>index</code></em> :10;</span></p></td>
742 <td>Index of the property that this function is a setter or getter of
743 in the array of properties of the containing interface, or index
744 of the virtual function that this function wraps.</td>
747 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="FunctionBlob.name"></a>name</code></em>;</span></p></td>
751 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="FunctionBlob.symbol"></a>symbol</code></em>;</span></p></td>
752 <td>The symbol which can be used to obtain the function pointer with
753 <code class="function">dlsym()</code>.</td>
756 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="FunctionBlob.signature"></a>signature</code></em>;</span></p></td>
757 <td>Offset of the SignatureBlob describing the parameter types and the
758 return value type.</td>
761 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="FunctionBlob.is-static"></a>is_static</code></em> : 1;</span></p></td>
762 <td>The function is a "static method"; in other words it's a pure
763 function whose name is conceptually scoped to the object.</td>
766 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="FunctionBlob.reserved"></a>reserved</code></em> : 15;</span></p></td>
770 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="FunctionBlob.reserved2"></a>reserved2</code></em> : 16;</span></p></td>
777 <div class="refsect2">
778 <a name="CallbackBlob"></a><h3>CallbackBlob</h3>
779 <pre class="programlisting">typedef struct {
780 guint16 blob_type; /* 2 */
782 guint16 deprecated : 1;
787 <div class="variablelist"><table border="0">
788 <col align="left" valign="top">
791 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="CallbackBlob.blob-type"></a>blob_type</code></em>;</span></p></td>
795 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="CallbackBlob.deprecated"></a>deprecated</code></em> : 1;</span></p></td>
799 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="CallbackBlob.name"></a>name</code></em>;</span></p></td>
803 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="CallbackBlob.signature"></a>signature</code></em>;</span></p></td>
804 <td>Offset of the <a class="link" href="gi-gtypelib.html#SignatureBlob" title="SignatureBlob"><span class="type">SignatureBlob</span></a> describing the parameter types and the
805 return value type.</td>
811 <div class="refsect2">
812 <a name="InterfaceTypeBlob"></a><h3>InterfaceTypeBlob</h3>
813 <pre class="programlisting">typedef struct {
820 If the interface is an enum of flags type, is_pointer is 0, otherwise it is 1.
822 <div class="variablelist"><table border="0">
823 <col align="left" valign="top">
826 <td><p><span class="term"><span class="type">guint8</span> <em class="structfield"><code><a name="InterfaceTypeBlob.pointer"></a>pointer</code></em> :1;</span></p></td>
827 <td>Whether this type represents an indirection</td>
830 <td><p><span class="term"><span class="type">guint8</span> <em class="structfield"><code><a name="InterfaceTypeBlob.tag"></a>tag</code></em> :5;</span></p></td>
831 <td>A <a class="link" href="gi-GITypeInfo.html#GITypeTag" title="enum GITypeTag"><span class="type">GITypeTag</span></a>
835 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="InterfaceTypeBlob.interface"></a>interface</code></em>;</span></p></td>
836 <td>Index of the directory entry for the interface.</td>
842 <div class="refsect2">
843 <a name="ParamTypeBlob"></a><h3>ParamTypeBlob</h3>
844 <pre class="programlisting">typedef struct {
852 SimpleTypeBlob type[];
855 <div class="variablelist"><table border="0">
856 <col align="left" valign="top">
859 <td><p><span class="term"><span class="type">guint8</span> <em class="structfield"><code><a name="ParamTypeBlob.pointer"></a>pointer</code></em> :1;</span></p></td>
863 <td><p><span class="term"><span class="type">guint8</span> <em class="structfield"><code><a name="ParamTypeBlob.reserved"></a>reserved</code></em> :2;</span></p></td>
867 <td><p><span class="term"><span class="type">guint8</span> <em class="structfield"><code><a name="ParamTypeBlob.tag"></a>tag</code></em> :5;</span></p></td>
871 <td><p><span class="term"><span class="type">guint8</span> <em class="structfield"><code><a name="ParamTypeBlob.reserved2"></a>reserved2</code></em>;</span></p></td>
875 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="ParamTypeBlob.n-types"></a>n_types</code></em>;</span></p></td>
876 <td>The number of parameter types to follow.</td>
879 <td><p><span class="term"><span class="type">SimpleTypeBlob</span> <em class="structfield"><code><a name="ParamTypeBlob.type"></a>type</code></em>[];</span></p></td>
880 <td>Describes the type of the list elements.</td>
886 <div class="refsect2">
887 <a name="ErrorTypeBlob"></a><h3>ErrorTypeBlob</h3>
888 <pre class="programlisting">typedef struct {
895 guint16 n_domains; /* Must be 0 */
901 <div class="refsect2">
902 <a name="ValueBlob"></a><h3>ValueBlob</h3>
903 <pre class="programlisting">typedef struct {
904 guint32 deprecated : 1;
905 guint32 unsigned_value : 1;
911 Values commonly occur in enums and flags.
913 <div class="variablelist"><table border="0">
914 <col align="left" valign="top">
917 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="ValueBlob.deprecated"></a>deprecated</code></em> : 1;</span></p></td>
918 <td>Whether this value is deprecated</td>
921 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="ValueBlob.unsigned-value"></a>unsigned_value</code></em> : 1;</span></p></td>
922 <td>if set, value is a 32-bit unsigned integer cast to gint32</td>
925 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="ValueBlob.name"></a>name</code></em>;</span></p></td>
926 <td>Name of blob</td>
929 <td><p><span class="term"><span class="type">gint32</span> <em class="structfield"><code><a name="ValueBlob.value"></a>value</code></em>;</span></p></td>
930 <td>The numerical value</td>
936 <div class="refsect2">
937 <a name="FieldBlob"></a><h3>FieldBlob</h3>
938 <pre class="programlisting">typedef struct {
943 guint8 has_embedded_type :1;
947 guint16 struct_offset;
954 <div class="variablelist"><table border="0">
955 <col align="left" valign="top">
958 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="FieldBlob.name"></a>name</code></em>;</span></p></td>
959 <td>The name of the field.</td>
962 <td><p><span class="term"><span class="type">guint8</span> <em class="structfield"><code><a name="FieldBlob.readable"></a>readable</code></em> :1;</span></p></td>
966 <td><p><span class="term"><span class="type">guint8</span> <em class="structfield"><code><a name="FieldBlob.writable"></a>writable</code></em> :1;</span></p></td>
967 <td>How the field may be accessed.</td>
970 <td><p><span class="term"><span class="type">guint8</span> <em class="structfield"><code><a name="FieldBlob.has-embedded-type"></a>has_embedded_type</code></em> :1;</span></p></td>
971 <td>An anonymous type follows the FieldBlob.</td>
974 <td><p><span class="term"><span class="type">guint8</span> <em class="structfield"><code><a name="FieldBlob.reserved"></a>reserved</code></em> :5;</span></p></td>
978 <td><p><span class="term"><span class="type">guint8</span> <em class="structfield"><code><a name="FieldBlob.bits"></a>bits</code></em>;</span></p></td>
979 <td>If this field is part of a bitfield, the number of bits which it
980 uses, otherwise 0.</td>
983 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="FieldBlob.struct-offset"></a>struct_offset</code></em>;</span></p></td>
984 <td>The offset of the field in the struct. The value 0xFFFF indicates
985 that the struct offset is unknown.</td>
988 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="FieldBlob.reserved2"></a>reserved2</code></em>;</span></p></td>
992 <td><p><span class="term"><span class="type">SimpleTypeBlob</span> <em class="structfield"><code><a name="FieldBlob.type"></a>type</code></em>;</span></p></td>
993 <td>The type of the field.</td>
999 <div class="refsect2">
1000 <a name="RegisteredTypeBlob"></a><h3>RegisteredTypeBlob</h3>
1001 <pre class="programlisting">typedef struct {
1003 guint16 deprecated : 1;
1004 guint16 unregistered : 1;
1005 guint16 reserved :14;
1010 } RegisteredTypeBlob;
1012 <div class="variablelist"><table border="0">
1013 <col align="left" valign="top">
1016 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="RegisteredTypeBlob.blob-type"></a>blob_type</code></em>;</span></p></td>
1020 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="RegisteredTypeBlob.deprecated"></a>deprecated</code></em> : 1;</span></p></td>
1024 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="RegisteredTypeBlob.unregistered"></a>unregistered</code></em> : 1;</span></p></td>
1028 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="RegisteredTypeBlob.reserved"></a>reserved</code></em> :14;</span></p></td>
1032 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="RegisteredTypeBlob.name"></a>name</code></em>;</span></p></td>
1036 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="RegisteredTypeBlob.gtype-name"></a>gtype_name</code></em>;</span></p></td>
1037 <td>The name under which the type is registered with GType.</td>
1040 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="RegisteredTypeBlob.gtype-init"></a>gtype_init</code></em>;</span></p></td>
1041 <td>The symbol name of the <code class="function">get_type()</code> function which registers the type.</td>
1047 <div class="refsect2">
1048 <a name="StructBlob"></a><h3>StructBlob</h3>
1049 <pre class="programlisting">typedef struct {
1052 guint16 deprecated : 1;
1053 guint16 unregistered : 1;
1054 guint16 is_gtype_struct : 1;
1055 guint16 alignment : 6;
1056 guint16 foreign : 1;
1057 guint16 reserved : 6;
1073 /* variable-length parts of the blob */
1075 FunctionBlob methods[];
1079 <div class="variablelist"><table border="0">
1080 <col align="left" valign="top">
1083 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="StructBlob.blob-type"></a>blob_type</code></em>;</span></p></td>
1084 <td><a class="link" href="gi-gtypelib.html#BLOB-TYPE-STRUCT:CAPS"><span class="type">BLOB_TYPE_STRUCT</span></a></td>
1087 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="StructBlob.deprecated"></a>deprecated</code></em> : 1;</span></p></td>
1088 <td>Whether this structure is deprecated</td>
1091 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="StructBlob.unregistered"></a>unregistered</code></em> : 1;</span></p></td>
1092 <td>If this is set, the type is not registered with GType.</td>
1095 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="StructBlob.is-gtype-struct"></a>is_gtype_struct</code></em> : 1;</span></p></td>
1096 <td>Whether this structure is the class or interface layout for a GObject</td>
1099 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="StructBlob.alignment"></a>alignment</code></em> : 6;</span></p></td>
1100 <td>The byte boundary that the struct is aligned to in memory</td>
1103 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="StructBlob.foreign"></a>foreign</code></em> : 1;</span></p></td>
1104 <td>If the type is foreign, eg if it's expected to be overridden by
1105 a native language binding instead of relying of introspected bindings.</td>
1108 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="StructBlob.reserved"></a>reserved</code></em> : 6;</span></p></td>
1112 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="StructBlob.name"></a>name</code></em>;</span></p></td>
1116 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="StructBlob.gtype-name"></a>gtype_name</code></em>;</span></p></td>
1117 <td>String name of the associated <span class="type">GType</span>
1121 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="StructBlob.gtype-init"></a>gtype_init</code></em>;</span></p></td>
1122 <td>String naming the symbol which gets the runtime <span class="type">GType</span>
1126 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="StructBlob.size"></a>size</code></em>;</span></p></td>
1127 <td>The size of the struct in bytes.</td>
1130 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="StructBlob.n-fields"></a>n_fields</code></em>;</span></p></td>
1134 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="StructBlob.n-methods"></a>n_methods</code></em>;</span></p></td>
1138 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="StructBlob.reserved2"></a>reserved2</code></em>;</span></p></td>
1142 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="StructBlob.reserved3"></a>reserved3</code></em>;</span></p></td>
1146 <td><p><span class="term"><a class="link" href="gi-gtypelib.html#FieldBlob" title="FieldBlob"><span class="type">FieldBlob</span></a> <em class="structfield"><code><a name="StructBlob.fields"></a>fields</code></em>[];</span></p></td>
1147 <td>An array of n_fields FieldBlobs.
1148 should be considered as methods of the struct.</td>
1151 <td><p><span class="term"><a class="link" href="gi-gtypelib.html#FunctionBlob" title="FunctionBlob"><span class="type">FunctionBlob</span></a> <em class="structfield"><code><a name="StructBlob.methods"></a>methods</code></em>[];</span></p></td>
1158 <div class="refsect2">
1159 <a name="UnionBlob"></a><h3>UnionBlob</h3>
1160 <pre class="programlisting">typedef struct {
1162 guint16 deprecated : 1;
1163 guint16 unregistered : 1;
1164 guint16 discriminated : 1;
1165 guint16 alignment : 6;
1166 guint16 reserved : 7;
1175 guint16 n_functions;
1180 gint32 discriminator_offset;
1181 SimpleTypeBlob discriminator_type;
1185 FunctionBlob functions[];
1186 ConstantBlob discriminator_values[]
1190 <div class="variablelist"><table border="0">
1191 <col align="left" valign="top">
1194 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="UnionBlob.blob-type"></a>blob_type</code></em>;</span></p></td>
1198 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="UnionBlob.deprecated"></a>deprecated</code></em> : 1;</span></p></td>
1202 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="UnionBlob.unregistered"></a>unregistered</code></em> : 1;</span></p></td>
1203 <td>If this is set, the type is not registered with GType.</td>
1206 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="UnionBlob.discriminated"></a>discriminated</code></em> : 1;</span></p></td>
1207 <td>Is set if the union is discriminated</td>
1210 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="UnionBlob.alignment"></a>alignment</code></em> : 6;</span></p></td>
1211 <td>The byte boundary that the union is aligned to in memory</td>
1214 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="UnionBlob.reserved"></a>reserved</code></em> : 7;</span></p></td>
1218 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="UnionBlob.name"></a>name</code></em>;</span></p></td>
1222 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="UnionBlob.gtype-name"></a>gtype_name</code></em>;</span></p></td>
1223 <td>String name of the associated <span class="type">GType</span>
1227 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="UnionBlob.gtype-init"></a>gtype_init</code></em>;</span></p></td>
1228 <td>String naming the symbol which gets the runtime <span class="type">GType</span>
1232 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="UnionBlob.size"></a>size</code></em>;</span></p></td>
1233 <td>The size of the union in bytes.</td>
1236 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="UnionBlob.n-fields"></a>n_fields</code></em>;</span></p></td>
1237 <td>Length of the arrays</td>
1240 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="UnionBlob.n-functions"></a>n_functions</code></em>;</span></p></td>
1244 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="UnionBlob.reserved2"></a>reserved2</code></em>;</span></p></td>
1248 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="UnionBlob.reserved3"></a>reserved3</code></em>;</span></p></td>
1252 <td><p><span class="term"><span class="type">gint32</span> <em class="structfield"><code><a name="UnionBlob.discriminator-offset"></a>discriminator_offset</code></em>;</span></p></td>
1253 <td>Offset from the beginning of the union where the
1254 discriminator of a discriminated union is located.
1255 The value 0xFFFF indicates that the discriminator offset
1259 <td><p><span class="term"><span class="type">SimpleTypeBlob</span> <em class="structfield"><code><a name="UnionBlob.discriminator-type"></a>discriminator_type</code></em>;</span></p></td>
1260 <td>Type of the discriminator</td>
1263 <td><p><span class="term"><a class="link" href="gi-gtypelib.html#FieldBlob" title="FieldBlob"><span class="type">FieldBlob</span></a> <em class="structfield"><code><a name="UnionBlob.fields"></a>fields</code></em>[];</span></p></td>
1264 <td>Array of FieldBlobs describing the alternative branches of the union</td>
1267 <td><p><span class="term"><a class="link" href="gi-gtypelib.html#FunctionBlob" title="FunctionBlob"><span class="type">FunctionBlob</span></a> <em class="structfield"><code><a name="UnionBlob.functions"></a>functions</code></em>[];</span></p></td>
1274 <div class="refsect2">
1275 <a name="EnumBlob"></a><h3>EnumBlob</h3>
1276 <pre class="programlisting">typedef struct {
1279 guint16 deprecated : 1;
1280 guint16 unregistered : 1;
1281 guint16 storage_type : 5;
1282 guint16 reserved : 9;
1292 guint32 error_domain;
1296 FunctionBlob methods[];
1300 <div class="variablelist"><table border="0">
1301 <col align="left" valign="top">
1304 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="EnumBlob.blob-type"></a>blob_type</code></em>;</span></p></td>
1308 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="EnumBlob.deprecated"></a>deprecated</code></em> : 1;</span></p></td>
1312 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="EnumBlob.unregistered"></a>unregistered</code></em> : 1;</span></p></td>
1313 <td>If this is set, the type is not registered with GType.</td>
1316 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="EnumBlob.storage-type"></a>storage_type</code></em> : 5;</span></p></td>
1317 <td>The tag of the type used for the enum in the C ABI
1318 (will be a signed or unsigned integral type)</td>
1321 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="EnumBlob.reserved"></a>reserved</code></em> : 9;</span></p></td>
1325 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="EnumBlob.name"></a>name</code></em>;</span></p></td>
1329 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="EnumBlob.gtype-name"></a>gtype_name</code></em>;</span></p></td>
1330 <td>String name of the associated <span class="type">GType</span>
1334 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="EnumBlob.gtype-init"></a>gtype_init</code></em>;</span></p></td>
1335 <td>String naming the symbol which gets the runtime <span class="type">GType</span>
1339 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="EnumBlob.n-values"></a>n_values</code></em>;</span></p></td>
1340 <td>The length of the values array.</td>
1343 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="EnumBlob.n-methods"></a>n_methods</code></em>;</span></p></td>
1344 <td>The length of the methods array.</td>
1347 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="EnumBlob.error-domain"></a>error_domain</code></em>;</span></p></td>
1348 <td>String naming the <span class="type">GError</span> domain this enum is
1349 associated with</td>
1352 <td><p><span class="term"><a class="link" href="gi-gtypelib.html#ValueBlob" title="ValueBlob"><span class="type">ValueBlob</span></a> <em class="structfield"><code><a name="EnumBlob.values"></a>values</code></em>[];</span></p></td>
1353 <td>Describes the enum values.</td>
1356 <td><p><span class="term"><a class="link" href="gi-gtypelib.html#FunctionBlob" title="FunctionBlob"><span class="type">FunctionBlob</span></a> <em class="structfield"><code><a name="EnumBlob.methods"></a>methods</code></em>[];</span></p></td>
1357 <td>Describes the enum methods.</td>
1363 <div class="refsect2">
1364 <a name="PropertyBlob"></a><h3>PropertyBlob</h3>
1365 <pre class="programlisting">typedef struct {
1368 guint32 deprecated : 1;
1369 guint32 readable : 1;
1370 guint32 writable : 1;
1371 guint32 construct : 1;
1372 guint32 construct_only : 1;
1373 guint32 transfer_ownership : 1;
1374 guint32 transfer_container_ownership : 1;
1375 guint32 reserved :25;
1379 SimpleTypeBlob type;
1382 <div class="variablelist"><table border="0">
1383 <col align="left" valign="top">
1386 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="PropertyBlob.name"></a>name</code></em>;</span></p></td>
1387 <td>The name of the property.</td>
1390 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="PropertyBlob.deprecated"></a>deprecated</code></em> : 1;</span></p></td>
1394 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="PropertyBlob.readable"></a>readable</code></em> : 1;</span></p></td>
1398 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="PropertyBlob.writable"></a>writable</code></em> : 1;</span></p></td>
1402 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="PropertyBlob.construct"></a>construct</code></em> : 1;</span></p></td>
1406 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="PropertyBlob.construct-only"></a>construct_only</code></em> : 1;</span></p></td>
1407 <td>The ParamFlags used when registering the property.</td>
1410 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="PropertyBlob.transfer-ownership"></a>transfer_ownership</code></em> : 1;</span></p></td>
1411 <td>When writing, the type containing the property takes
1412 ownership of the value. When reading, the returned value needs to be released
1416 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="PropertyBlob.transfer-container-ownership"></a>transfer_container_ownership</code></em> : 1;</span></p></td>
1417 <td>For container types indicates that the
1418 ownership of the container, but not of its contents, is transferred. This is
1419 typically the case when reading lists of statically allocated things.</td>
1422 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="PropertyBlob.reserved"></a>reserved</code></em> :25;</span></p></td>
1426 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="PropertyBlob.reserved2"></a>reserved2</code></em>;</span></p></td>
1430 <td><p><span class="term"><span class="type">SimpleTypeBlob</span> <em class="structfield"><code><a name="PropertyBlob.type"></a>type</code></em>;</span></p></td>
1431 <td>Describes the type of the property.</td>
1437 <div class="refsect2">
1438 <a name="SignalBlob"></a><h3>SignalBlob</h3>
1439 <pre class="programlisting">typedef struct {
1440 guint16 deprecated : 1;
1441 guint16 run_first : 1;
1442 guint16 run_last : 1;
1443 guint16 run_cleanup : 1;
1444 guint16 no_recurse : 1;
1445 guint16 detailed : 1;
1447 guint16 no_hooks : 1;
1448 guint16 has_class_closure : 1;
1449 guint16 true_stops_emit : 1;
1450 guint16 reserved : 6;
1452 guint16 class_closure;
1461 <div class="variablelist"><table border="0">
1462 <col align="left" valign="top">
1465 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="SignalBlob.deprecated"></a>deprecated</code></em> : 1;</span></p></td>
1469 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="SignalBlob.run-first"></a>run_first</code></em> : 1;</span></p></td>
1473 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="SignalBlob.run-last"></a>run_last</code></em> : 1;</span></p></td>
1477 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="SignalBlob.run-cleanup"></a>run_cleanup</code></em> : 1;</span></p></td>
1481 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="SignalBlob.no-recurse"></a>no_recurse</code></em> : 1;</span></p></td>
1485 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="SignalBlob.detailed"></a>detailed</code></em> : 1;</span></p></td>
1489 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="SignalBlob.action"></a>action</code></em> : 1;</span></p></td>
1493 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="SignalBlob.no-hooks"></a>no_hooks</code></em> : 1;</span></p></td>
1494 <td>The flags used when registering the signal.</td>
1497 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="SignalBlob.has-class-closure"></a>has_class_closure</code></em> : 1;</span></p></td>
1498 <td>Set if the signal has a class closure.</td>
1501 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="SignalBlob.true-stops-emit"></a>true_stops_emit</code></em> : 1;</span></p></td>
1502 <td>Whether the signal has true-stops-emit semantics</td>
1505 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="SignalBlob.reserved"></a>reserved</code></em> : 6;</span></p></td>
1509 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="SignalBlob.class-closure"></a>class_closure</code></em>;</span></p></td>
1510 <td>The index of the class closure in the list of virtual functions
1511 of the object or interface on which the signal is defined.</td>
1514 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="SignalBlob.name"></a>name</code></em>;</span></p></td>
1515 <td>The name of the signal.</td>
1518 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="SignalBlob.reserved2"></a>reserved2</code></em>;</span></p></td>
1522 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="SignalBlob.signature"></a>signature</code></em>;</span></p></td>
1523 <td>Offset of the SignatureBlob describing the parameter types and the
1524 return value type.</td>
1530 <div class="refsect2">
1531 <a name="VFuncBlob"></a><h3>VFuncBlob</h3>
1532 <pre class="programlisting">typedef struct {
1535 guint16 must_chain_up : 1;
1536 guint16 must_be_implemented : 1;
1537 guint16 must_not_be_implemented : 1;
1538 guint16 class_closure : 1;
1540 guint16 reserved :11;
1543 guint16 struct_offset;
1544 guint16 invoker : 10; /* Number of bits matches @index in FunctionBlob */
1545 guint16 reserved2 : 6;
1551 <div class="variablelist"><table border="0">
1552 <col align="left" valign="top">
1555 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="VFuncBlob.name"></a>name</code></em>;</span></p></td>
1556 <td>The name of the virtual function.</td>
1559 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="VFuncBlob.must-chain-up"></a>must_chain_up</code></em> : 1;</span></p></td>
1560 <td>If set, every implementation of this virtual function must
1561 chain up to the implementation of the parent class.</td>
1564 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="VFuncBlob.must-be-implemented"></a>must_be_implemented</code></em> : 1;</span></p></td>
1565 <td>If set, every derived class must override this virtual function.</td>
1568 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="VFuncBlob.must-not-be-implemented"></a>must_not_be_implemented</code></em> : 1;</span></p></td>
1569 <td>If set, derived class must not override this virtual function.</td>
1572 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="VFuncBlob.class-closure"></a>class_closure</code></em> : 1;</span></p></td>
1573 <td>Set if this virtual function is the class closure of a signal.</td>
1576 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="VFuncBlob.throws"></a>throws</code></em> : 1;</span></p></td>
1580 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="VFuncBlob.reserved"></a>reserved</code></em> :11;</span></p></td>
1584 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="VFuncBlob.signal"></a>signal</code></em>;</span></p></td>
1585 <td>The index of the signal in the list of signals of the object or
1586 interface to which this virtual function belongs.</td>
1589 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="VFuncBlob.struct-offset"></a>struct_offset</code></em>;</span></p></td>
1590 <td>The offset of the function pointer in the class struct. The value
1591 0xFFFF indicates that the struct offset is unknown.</td>
1594 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="VFuncBlob.invoker"></a>invoker</code></em> : 10;</span></p></td>
1595 <td>If a method invoker for this virtual exists, this is the offset in the
1596 class structure of the method. If no method is known, this value will be 0x3ff.</td>
1599 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="VFuncBlob.reserved2"></a>reserved2</code></em> : 6;</span></p></td>
1603 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="VFuncBlob.reserved3"></a>reserved3</code></em>;</span></p></td>
1607 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="VFuncBlob.signature"></a>signature</code></em>;</span></p></td>
1608 <td>Offset of the SignatureBlob describing the parameter types and the
1609 return value type.</td>
1615 <div class="refsect2">
1616 <a name="ObjectBlob"></a><h3>ObjectBlob</h3>
1617 <pre class="programlisting">typedef struct {
1618 guint16 blob_type; /* 7 */
1619 guint16 deprecated : 1;
1620 guint16 abstract : 1;
1621 guint16 fundamental : 1;
1622 guint16 reserved :13;
1629 guint16 gtype_struct;
1631 guint16 n_interfaces;
1633 guint16 n_properties;
1637 guint16 n_constants;
1642 guint32 set_value_func;
1643 guint32 get_value_func;
1648 guint16 interfaces[];
1651 /* variable-length parts of the blob */
1653 PropertyBlob properties[];
1654 FunctionBlob methods[];
1655 SignalBlob signals[];
1657 ConstantBlob constants[];
1661 <div class="variablelist"><table border="0">
1662 <col align="left" valign="top">
1665 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="ObjectBlob.blob-type"></a>blob_type</code></em>;</span></p></td>
1666 <td><a class="link" href="gi-gtypelib.html#BLOB-TYPE-OBJECT:CAPS"><span class="type">BLOB_TYPE_OBJECT</span></a></td>
1669 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="ObjectBlob.deprecated"></a>deprecated</code></em> : 1;</span></p></td>
1673 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="ObjectBlob.abstract"></a>abstract</code></em> : 1;</span></p></td>
1677 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="ObjectBlob.fundamental"></a>fundamental</code></em> : 1;</span></p></td>
1678 <td>this object is not a GObject derived type, instead it's
1679 an additional fundamental type.</td>
1682 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="ObjectBlob.reserved"></a>reserved</code></em> :13;</span></p></td>
1686 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="ObjectBlob.name"></a>name</code></em>;</span></p></td>
1690 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="ObjectBlob.gtype-name"></a>gtype_name</code></em>;</span></p></td>
1691 <td>String name of the associated <span class="type">GType</span>
1695 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="ObjectBlob.gtype-init"></a>gtype_init</code></em>;</span></p></td>
1696 <td>String naming the symbol which gets the runtime <span class="type">GType</span>
1700 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="ObjectBlob.parent"></a>parent</code></em>;</span></p></td>
1701 <td>The directory index of the parent type. This is only set for
1702 objects. If an object does not have a parent, it is zero.</td>
1705 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="ObjectBlob.gtype-struct"></a>gtype_struct</code></em>;</span></p></td>
1709 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="ObjectBlob.n-interfaces"></a>n_interfaces</code></em>;</span></p></td>
1713 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="ObjectBlob.n-fields"></a>n_fields</code></em>;</span></p></td>
1717 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="ObjectBlob.n-properties"></a>n_properties</code></em>;</span></p></td>
1721 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="ObjectBlob.n-methods"></a>n_methods</code></em>;</span></p></td>
1725 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="ObjectBlob.n-signals"></a>n_signals</code></em>;</span></p></td>
1729 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="ObjectBlob.n-vfuncs"></a>n_vfuncs</code></em>;</span></p></td>
1733 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="ObjectBlob.n-constants"></a>n_constants</code></em>;</span></p></td>
1734 <td>The lengths of the arrays.Up to 16bits of padding may be inserted
1735 between the arrays to ensure that they start on a 32bit boundary.</td>
1738 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="ObjectBlob.reserved2"></a>reserved2</code></em>;</span></p></td>
1742 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="ObjectBlob.ref-func"></a>ref_func</code></em>;</span></p></td>
1743 <td>String pointing to a function which can be called to increase
1744 the reference count for an instance of this object type.</td>
1747 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="ObjectBlob.unref-func"></a>unref_func</code></em>;</span></p></td>
1748 <td>String pointing to a function which can be called to decrease
1749 the reference count for an instance of this object type.</td>
1752 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="ObjectBlob.set-value-func"></a>set_value_func</code></em>;</span></p></td>
1753 <td>String pointing to a function which can be called to
1754 convert a pointer of this object to a GValue</td>
1757 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="ObjectBlob.get-value-func"></a>get_value_func</code></em>;</span></p></td>
1758 <td>String pointing to a function which can be called to
1759 convert extract a pointer to this object from a GValue</td>
1762 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="ObjectBlob.reserved3"></a>reserved3</code></em>;</span></p></td>
1766 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="ObjectBlob.reserved4"></a>reserved4</code></em>;</span></p></td>
1770 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="ObjectBlob.interfaces"></a>interfaces</code></em>[];</span></p></td>
1771 <td>An array of indices of directory entries for the implemented
1775 <td><p><span class="term"><a class="link" href="gi-gtypelib.html#FieldBlob" title="FieldBlob"><span class="type">FieldBlob</span></a> <em class="structfield"><code><a name="ObjectBlob.fields"></a>fields</code></em>[];</span></p></td>
1776 <td>Describes the fields.</td>
1779 <td><p><span class="term"><a class="link" href="gi-gtypelib.html#PropertyBlob" title="PropertyBlob"><span class="type">PropertyBlob</span></a> <em class="structfield"><code><a name="ObjectBlob.properties"></a>properties</code></em>[];</span></p></td>
1780 <td>Describes the properties.</td>
1783 <td><p><span class="term"><a class="link" href="gi-gtypelib.html#FunctionBlob" title="FunctionBlob"><span class="type">FunctionBlob</span></a> <em class="structfield"><code><a name="ObjectBlob.methods"></a>methods</code></em>[];</span></p></td>
1784 <td>Describes the methods, constructors, setters and getters.</td>
1787 <td><p><span class="term"><a class="link" href="gi-gtypelib.html#SignalBlob" title="SignalBlob"><span class="type">SignalBlob</span></a> <em class="structfield"><code><a name="ObjectBlob.signals"></a>signals</code></em>[];</span></p></td>
1788 <td>Describes the signals.</td>
1791 <td><p><span class="term"><a class="link" href="gi-gtypelib.html#VFuncBlob" title="VFuncBlob"><span class="type">VFuncBlob</span></a> <em class="structfield"><code><a name="ObjectBlob.vfuncs"></a>vfuncs</code></em>[];</span></p></td>
1792 <td>Describes the virtual functions.</td>
1795 <td><p><span class="term"><a class="link" href="gi-gtypelib.html#ConstantBlob" title="ConstantBlob"><span class="type">ConstantBlob</span></a> <em class="structfield"><code><a name="ObjectBlob.constants"></a>constants</code></em>[];</span></p></td>
1796 <td>Describes the constants.</td>
1802 <div class="refsect2">
1803 <a name="InterfaceBlob"></a><h3>InterfaceBlob</h3>
1804 <pre class="programlisting">typedef struct {
1806 guint16 deprecated : 1;
1807 guint16 reserved :15;
1812 guint16 gtype_struct;
1814 guint16 n_prerequisites;
1815 guint16 n_properties;
1819 guint16 n_constants;
1826 guint16 prerequisites[];
1829 /* variable-length parts of the blob */
1830 PropertyBlob properties[];
1831 FunctionBlob methods[];
1832 SignalBlob signals[];
1834 ConstantBlob constants[];
1838 <div class="variablelist"><table border="0">
1839 <col align="left" valign="top">
1842 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="InterfaceBlob.blob-type"></a>blob_type</code></em>;</span></p></td>
1846 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="InterfaceBlob.deprecated"></a>deprecated</code></em> : 1;</span></p></td>
1850 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="InterfaceBlob.reserved"></a>reserved</code></em> :15;</span></p></td>
1854 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="InterfaceBlob.name"></a>name</code></em>;</span></p></td>
1858 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="InterfaceBlob.gtype-name"></a>gtype_name</code></em>;</span></p></td>
1862 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="InterfaceBlob.gtype-init"></a>gtype_init</code></em>;</span></p></td>
1866 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="InterfaceBlob.gtype-struct"></a>gtype_struct</code></em>;</span></p></td>
1867 <td>Name of the interface "class" C structure</td>
1870 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="InterfaceBlob.n-prerequisites"></a>n_prerequisites</code></em>;</span></p></td>
1871 <td>Number of prerequisites</td>
1874 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="InterfaceBlob.n-properties"></a>n_properties</code></em>;</span></p></td>
1875 <td>Number of properties</td>
1878 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="InterfaceBlob.n-methods"></a>n_methods</code></em>;</span></p></td>
1879 <td>Number of methods</td>
1882 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="InterfaceBlob.n-signals"></a>n_signals</code></em>;</span></p></td>
1883 <td>Number of signals</td>
1886 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="InterfaceBlob.n-vfuncs"></a>n_vfuncs</code></em>;</span></p></td>
1887 <td>Number of virtual functions</td>
1890 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="InterfaceBlob.n-constants"></a>n_constants</code></em>;</span></p></td>
1891 <td>The lengths of the arrays.
1892 Up to 16bits of padding may be inserted between the arrays to ensure that they
1893 start on a 32bit boundary.</td>
1896 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="InterfaceBlob.padding"></a>padding</code></em>;</span></p></td>
1900 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="InterfaceBlob.reserved2"></a>reserved2</code></em>;</span></p></td>
1904 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="InterfaceBlob.reserved3"></a>reserved3</code></em>;</span></p></td>
1908 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="InterfaceBlob.prerequisites"></a>prerequisites</code></em>[];</span></p></td>
1909 <td>An array of indices of directory entries for required interfaces.</td>
1912 <td><p><span class="term"><a class="link" href="gi-gtypelib.html#PropertyBlob" title="PropertyBlob"><span class="type">PropertyBlob</span></a> <em class="structfield"><code><a name="InterfaceBlob.properties"></a>properties</code></em>[];</span></p></td>
1913 <td>Describes the properties.</td>
1916 <td><p><span class="term"><a class="link" href="gi-gtypelib.html#FunctionBlob" title="FunctionBlob"><span class="type">FunctionBlob</span></a> <em class="structfield"><code><a name="InterfaceBlob.methods"></a>methods</code></em>[];</span></p></td>
1917 <td>Describes the methods, constructors, setters and getters.</td>
1920 <td><p><span class="term"><a class="link" href="gi-gtypelib.html#SignalBlob" title="SignalBlob"><span class="type">SignalBlob</span></a> <em class="structfield"><code><a name="InterfaceBlob.signals"></a>signals</code></em>[];</span></p></td>
1921 <td>Describes the signals.</td>
1924 <td><p><span class="term"><a class="link" href="gi-gtypelib.html#VFuncBlob" title="VFuncBlob"><span class="type">VFuncBlob</span></a> <em class="structfield"><code><a name="InterfaceBlob.vfuncs"></a>vfuncs</code></em>[];</span></p></td>
1925 <td>Describes the virtual functions.</td>
1928 <td><p><span class="term"><a class="link" href="gi-gtypelib.html#ConstantBlob" title="ConstantBlob"><span class="type">ConstantBlob</span></a> <em class="structfield"><code><a name="InterfaceBlob.constants"></a>constants</code></em>[];</span></p></td>
1929 <td>Describes the constants.</td>
1935 <div class="refsect2">
1936 <a name="ConstantBlob"></a><h3>ConstantBlob</h3>
1937 <pre class="programlisting">typedef struct {
1939 guint16 deprecated : 1;
1940 guint16 reserved :15;
1943 SimpleTypeBlob type;
1951 <div class="variablelist"><table border="0">
1952 <col align="left" valign="top">
1955 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="ConstantBlob.blob-type"></a>blob_type</code></em>;</span></p></td>
1959 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="ConstantBlob.deprecated"></a>deprecated</code></em> : 1;</span></p></td>
1963 <td><p><span class="term"><span class="type">guint16</span> <em class="structfield"><code><a name="ConstantBlob.reserved"></a>reserved</code></em> :15;</span></p></td>
1967 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="ConstantBlob.name"></a>name</code></em>;</span></p></td>
1971 <td><p><span class="term"><span class="type">SimpleTypeBlob</span> <em class="structfield"><code><a name="ConstantBlob.type"></a>type</code></em>;</span></p></td>
1972 <td>The type of the value. In most cases this should be a numeric
1973 type or string.</td>
1976 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="ConstantBlob.size"></a>size</code></em>;</span></p></td>
1977 <td>The size of the value in bytes.</td>
1980 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="ConstantBlob.offset"></a>offset</code></em>;</span></p></td>
1981 <td>The offset of the value in the typelib.</td>
1984 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="ConstantBlob.reserved2"></a>reserved2</code></em>;</span></p></td>
1991 <div class="refsect2">
1992 <a name="AttributeBlob"></a><h3>AttributeBlob</h3>
1993 <pre class="programlisting">typedef struct {
1999 <div class="variablelist"><table border="0">
2000 <col align="left" valign="top">
2003 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="AttributeBlob.offset"></a>offset</code></em>;</span></p></td>
2004 <td>The offset of the typelib entry to which this attribute refers.
2005 Attributes are kept sorted by offset, so that the attributes
2006 of an entry can be found by a binary search.</td>
2009 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="AttributeBlob.name"></a>name</code></em>;</span></p></td>
2010 <td>The name of the attribute, a string.</td>
2013 <td><p><span class="term"><span class="type">guint32</span> <em class="structfield"><code><a name="AttributeBlob.value"></a>value</code></em>;</span></p></td>
2014 <td>The value of the attribute (also a string)</td>
2020 <div class="refsect2">
2021 <a name="g-typelib-get-dir-entry"></a><h3>g_typelib_get_dir_entry ()</h3>
2022 <pre class="programlisting"><a class="link" href="gi-gtypelib.html#DirEntry" title="DirEntry"><span class="returnvalue">DirEntry</span></a> * g_typelib_get_dir_entry (<em class="parameter"><code><a class="link" href="gi-girepository.html#GITypelib" title="GITypelib"><span class="type">GITypelib</span></a> *typelib</code></em>,
2023 <em class="parameter"><code><span class="type">guint16</span> index</code></em>);</pre>
2026 <div class="refsect2">
2027 <a name="g-typelib-check-sanity"></a><h3>g_typelib_check_sanity ()</h3>
2028 <pre class="programlisting"><span class="returnvalue">void</span> g_typelib_check_sanity (<em class="parameter"><code><span class="type">void</span></code></em>);</pre>
2031 <div class="refsect2">
2032 <a name="g-typelib-get-string"></a><h3>g_typelib_get_string()</h3>
2033 <pre class="programlisting">#define g_typelib_get_string(typelib,offset)</pre>
2036 <div class="refsect2">
2037 <a name="G-TYPELIB-ERROR:CAPS"></a><h3>G_TYPELIB_ERROR</h3>
2038 <pre class="programlisting">#define G_TYPELIB_ERROR (g_typelib_error_quark ())
2042 <div class="refsect2">
2043 <a name="g-typelib-validate"></a><h3>g_typelib_validate ()</h3>
2044 <pre class="programlisting"><span class="returnvalue">gboolean</span> g_typelib_validate (<em class="parameter"><code><a class="link" href="gi-girepository.html#GITypelib" title="GITypelib"><span class="type">GITypelib</span></a> *typelib</code></em>,
2045 <em class="parameter"><code><span class="type">GError</span> **error</code></em>);</pre>
2048 <div class="refsect2">
2049 <a name="BLOB-IS-REGISTERED-TYPE:CAPS"></a><h3>BLOB_IS_REGISTERED_TYPE()</h3>
2050 <pre class="programlisting">#define BLOB_IS_REGISTERED_TYPE(blob)</pre>
2054 <div class="footer">
2056 Generated by GTK-Doc V1.18.1</div>