summaryrefslogtreecommitdiff
path: root/docs
diff options
context:
space:
mode:
authorColin Walters <walters@src.gnome.org>2009-02-06 18:37:13 +0000
committerColin Walters <walters@src.gnome.org>2009-02-06 18:37:13 +0000
commitd1bf6a23c6fa14e918aa93e346237b1c832fb2ea (patch)
tree715bf149bfa948eed8a1da945e2c0984ea81df73 /docs
parent3ae9127e53032065df14be8539aba0cf50835386 (diff)
downloadgobject-introspection-d1bf6a23c6fa14e918aa93e346237b1c832fb2ea.tar.gz
Bug 551738 - Associate classes with their structs
Inside glibtransformer, we now look at structures ending in "Class" and see if they have an associated GlibObject (i.e. a structure of the same name without the "Class" suffix). If found, pair them up. The .gir file for <class> gains an attribute denoting its associated class struct. Any <record> many now have a glib:is-class-struct-for annotation which tells which (if any) <class> for which it defines the layout. In the .typelib, we record the association between the class and its structure. Generic structures however just have a boolean saying whether they're a class struct. (Going from a generic class struct to its class should not be necessary). Finally, we expose GIRepository APIs to access both bits of information from the .typelib. svn path=/trunk/; revision=1088
Diffstat (limited to 'docs')
-rw-r--r--docs/typelib-format.txt15
1 files changed, 12 insertions, 3 deletions
diff --git a/docs/typelib-format.txt b/docs/typelib-format.txt
index a47a9f78..68125cdf 100644
--- a/docs/typelib-format.txt
+++ b/docs/typelib-format.txt
@@ -1,7 +1,11 @@
GObject binary typelib for introspection
-----------------------------------------
-Version 0.8
+Version 0.9
+
+Changes since 0.8:
+- Add class struct concept to ObjectBlob
+- Add is_class_struct bit to StructBlob
Changes since 0.7:
- Add dependencies
@@ -847,7 +851,8 @@ struct StructBlob
guint deprecated : 1;
guint unregistered : 1;
guint alignment : 6;
- guint reserved : 8;
+ guint is_class_struct : 1
+ guint reserved : 7;
guint32 name;
GTypeBlob gtype;
@@ -866,6 +871,9 @@ unregistered:
alignment:
The byte boundary that the struct is aligned to in memory
+
+is_class_struct:
+ Whether this structure is the "class structure" for a GObject
size: The size of the struct in bytes.
@@ -918,7 +926,7 @@ n_values:
values: Describes the enum values.
-ObjectBlob (32 + x bytes)
+ObjectBlob (36 + x bytes)
struct ObjectBlob
{
@@ -931,6 +939,7 @@ struct ObjectBlob
GTypeBlob gtype;
guint16 parent;
+ guint16 class_struct;
guint16 n_interfaces;
guint16 n_fields;