Top | ![]() |
![]() |
![]() |
![]() |
EModule * | e_module_new () |
const gchar * | e_module_get_filename () |
GList * | e_module_load_all_in_directory () |
EModule * | e_module_load_file () |
void | (*ETypeFunc) () |
void | e_type_traverse () |
EModule *
e_module_new (const gchar *filename
);
Creates a new EModule that will load the specific shared library when in use.
Since: 3.4
const gchar *
e_module_get_filename (EModule *module
);
Returns the filename of the shared library for module
. The
string is owned by module
and should not be modified or freed.
Since: 3.4
GList *
e_module_load_all_in_directory (const gchar *dirname
);
Loads all the modules in the specified directory into memory. If
you want to unload them (enabling on-demand loading) you must call
g_type_module_unuse()
on all the modules. Free the returned list
with g_list_free()
.
Since: 3.4
EModule *
e_module_load_file (const gchar *filename
);
Load the module from the specified filename into memory. If
you want to unload it (enabling on-demand loading) you must call
g_type_module_unuse()
on the module.
Since: 3.16
void (*ETypeFunc) (GType type
,gpointer user_data
);
Specifies the type of functions passed to e_type_traverse()
.
Since: 3.4
void e_type_traverse (GType parent_type
,ETypeFunc func
,gpointer user_data
);
Calls func
for all instantiable subtypes of parent_type
.
This is often useful for extending functionality by way of EModule.
A module may register a subtype of parent_type
in its e_module_load()
function. Then later on the application will call e_type_traverse()
to instantiate all registered subtypes of parent_type
.
parent_type |
the root GType to traverse from |
|
func |
the function to call for each visited GType |
|
user_data |
user data to pass to the function |
Since: 3.4
struct EModule { GTypeModule parent; EModulePrivate *priv; };
Contains only private data that should be read and manipulated using the functions below.
Since: 3.4