Package: gobject

Function gobject:type-class-ref

Lambda List

gobject:type-class-ref (gtype)

Arguments

gtype -- a g:type-t type ID of a classed type

Return Value

The pointer to the g:type-class instance for the given gtype.

Details

Increments the reference count of the class instance belonging to gtype and returns the pointer to the class instance. This function will create the class instance if it does not exist already. Returns nil when gtype is not a valid type ID for a classed type.

Examples

(g:type-class-ref "GApplication") => #.(SB-SYS:INT-SAP #X55FA5306FE40)
(g:type-from-class *) => #<GTYPE :name "GApplication" :id 94533623145984>
(g:type-class-ref "GAction") => NIL
(g:type-class-ref "gdouble") => NIL
(g:type-class-ref "unknown") => NIL    
 

See also

2024-12-8