G-Golf Type Info low level API.
GITypeInfo — Struct representing a type.
GIBaseInfoInfo
+— GITypeInfo
GITypeInfo
represents a type. You can retrieve a type info from
an argument (see Arg Info), a functions return value (see
Function Info), a field (see GIFieldInfo
), a property (see
Property Info), a constant (see GIConstantInfo
) or for a
union discriminator (see GIUnionInfo
).
A type can either be a of a basic type which is a standard C primitive
type or an interface type. For interface types you need to call
g-type-info-get-interface
to get a reference to the base info for
that interface.
Note: in this section, the info argument is [must be] a pointer to
a GITypeInfo
.
Returns a string or #f
.
Obtains the string representation for info-type or #f
if it
does not exists.
info-type can either be a symbol
or an id
, a member
of the enum-set
of %gi-info-type (otherwise, #f
is
returned).
Returns #t
or #f
.
Obtains if the info type is passed as a reference.
Note that the types of out
and inout
parameters (see
%gi-direction) will only be pointers if the underlying type being
transferred is a pointer (i.e. only if the type of the C function’s
formal parameter is a pointer to a pointer).
Returns a symbol.
Obtains the type tag for info (see %gi-type-tag for the list of type tags).
Returns a pointer or #f
.
Obtains the parameter type n (the index of the parameter). When
there is no such n parameter, the procedure returns #f
.
Returns a pointer or #f
.
For interface
types (see %gi-type-tag) such as GObjects and
boxed values, this procedure returns a (pointer to a) GIBaseInfo
,
holding full information about the referenced type. You can then
inspect the type of the returned GIBaseInfo
to further query
whether it is a concrete GObject, a GInterface, a structure, etc. using
g-base-info-get-type.
Returns an interger.
Obtain the array length of the type. The type tag must be a array
(see %gi-type-tag), or -1 will returned.
Returns an interger.
Obtain the fixed array syze of the type. The type tag must be a
array
(see %gi-type-tag), or -1 will returned.
Returns #t
or #f
.
Obtains if the last element of the array is NULL
. The type tag
must be a array
(see %gi-type-tag), or #f
will
returned.
Returns a symbol or #f
.
Obtain the array type for this type (see %gi-array-type). If the
type tag of this type is not array, #f
will be returned.