TypeClass

An opaque structure used as the base of all classes.

Members

Functions

addPrivate
void addPrivate(size_t privateSize)

Registers a private structure for an instantiatable type.

getPrivate
void* getPrivate(gobject.types.GType privateType)
peekParent
gobject.type_class.TypeClass peekParent()

This is a convenience function often needed in class initializers. It returns the class structure of the immediate parent type of the class passed in. Since derived classes hold a reference count on their parent classes as long as they are instantiated, the returned class will always exist.

Static functions

peek
gobject.type_class.TypeClass peek(gobject.types.GType type)

This function is essentially the same as gobject.type_class.TypeClass.ref_, except that the classes reference count isn't incremented. As a consequence, this function may return null if the class of the type passed in does not currently exist (hasn't been referenced before).

peekStatic
gobject.type_class.TypeClass peekStatic(gobject.types.GType type)

A more efficient version of gobject.type_class.TypeClass.peek which works only for static types.

ref_
gobject.type_class.TypeClass ref_(gobject.types.GType type)

Increments the reference count of the class structure belonging to type. This function will demand-create the class if it doesn't exist already.