After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 630062 - [girepository] Add function to access parameterized types of GList/GSList/GHash
[girepository] Add function to access parameterized types of GList/GSList/GHash
Status: RESOLVED NOTABUG
Product: gobject-introspection
Classification: Platform
Component: general
unspecified
Other Linux
: Normal enhancement
: ---
Assigned To: gobject-introspection Maintainer(s)
gobject-introspection Maintainer(s)
Depends on:
Blocks: 628240
 
 
Reported: 2010-09-19 13:22 UTC by Serkan Kaba
Modified: 2015-02-07 16:52 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Serkan Kaba 2010-09-19 13:22:44 UTC
Please add support for accessing parameterized types added for bug #581685.

Would be good for Java-gnome (We can workaround by overrides but that isn't very pleasant.)
Comment 1 Johan (not receiving bugmail) Dahlin 2010-09-20 03:18:19 UTC
This is already supported, use:

type_info = g_arg_info_get_type(arg_info);
type_tag = g_type_info_get_tag(type_info);
switch (type_tag) {
   case GI_TYPE_TAG_GSLIST: {
     param_type_info = g_type_info_get_param_type(type_info, 0);
     param_type_tag = g_type_info_get_tag(param_type_info);
     .. element type of GSList ..
   }
}

In general, when in doubt look at source code for gjs/seed/pygobject for examples on how to use the girepository api when the documentation is not clear enough.
Comment 2 Serkan Kaba 2010-09-20 10:16:56 UTC
Thought that was used for arrays only. Thanks for the pointers. Sorry for bugspam.
Comment 3 André Klapper 2015-02-07 16:52:40 UTC
[Mass-moving gobject-introspection tickets to its own Bugzilla product - see bug 708029. Mass-filter your bugmail for this message: introspection20150207 ]