Module


Defines

#define EINA_MODULE_INIT(f)   EAPI Eina_Module_Init __eina_module_init = &f;
#define EINA_MODULE_SHUTDOWN(f)   EAPI Eina_Module_Shutdown __eina_module_shutdown = &f;

Typedefs

typedef struct _Eina_Module Eina_Module
typedef Eina_Bool(* Eina_Module_Cb )(Eina_Module *m, void *data)
typedef Eina_Bool(* Eina_Module_Init )(void)
typedef void(* Eina_Module_Shutdown )(void)

Functions

EAPI int eina_module_init (void)
 To be documented FIXME: To be fixed.
EAPI int eina_module_shutdown (void)
 To be documented FIXME: To be fixed.
EAPI Eina_Module * eina_module_new (const char *file) EINA_MALLOC EINA_WARN_UNUSED_RESULT EINA_ARG_NONNULL(1)
 To be documented FIXME: To be fixed.
EAPI Eina_Bool eina_module_delete (Eina_Module *m) EINA_ARG_NONNULL(1)
 To be documented FIXME: To be fixed.
EAPI Eina_Bool eina_module_load (Eina_Module *module) EINA_ARG_NONNULL(1)
 To be documented FIXME: To be fixed.
EAPI Eina_Bool eina_module_unload (Eina_Module *m) EINA_ARG_NONNULL(1)
 To be documented FIXME: To be fixed.
EAPI void * eina_module_symbol_get (Eina_Module *module, const char *symbol) EINA_PURE EINA_ARG_NONNULL(1
EAPI const char * eina_module_file_get (Eina_Module *m) EINA_PURE EINA_WARN_UNUSED_RESULT EINA_ARG_NONNULL(1)
 To be documented FIXME: To be fixed.
EAPI char * eina_module_symbol_path_get (const void *symbol, const char *sub_dir) EINA_PURE EINA_MALLOC EINA_ARG_NONNULL(1
EAPI char *EAPI char * eina_module_environment_path_get (const char *env, const char *sub_dir) EINA_PURE EINA_MALLOC EINA_ARG_NONNULL(1
EAPI char *EAPI char *EAPI
Eina_Array
eina_module_list_get (Eina_Array *array, const char *path, unsigned int recursive, Eina_Module_Cb cb, void *data) EINA_MALLOC EINA_ARG_NONNULL(2) EINA_WARN_UNUSED_RESULT
 Gets a list of modules found on the directory path.
EAPI void eina_module_list_load (Eina_Array *list) EINA_ARG_NONNULL(1)
 Load every module on the list of modules.
EAPI void eina_module_list_unload (Eina_Array *list) EINA_ARG_NONNULL(1)
 To be documented FIXME: To be fixed.
EAPI void eina_module_list_delete (Eina_Array *list) EINA_ARG_NONNULL(1)
 Helper function that iterates over the list of modules and calls eina_module_delete on each.

Variables

EAPI Eina_Error EINA_ERROR_WRONG_MODULE
EAPI Eina_Error EINA_ERROR_MODULE_INIT_FAILED
EAPI void * EINA_WARN_UNUSED_RESULT

Function Documentation

EAPI char* EAPI char* EAPI Eina_Array* eina_module_list_get ( Eina_Array array,
const char *  path,
unsigned int  recursive,
Eina_Module_Cb  cb,
void *  data 
)

Gets a list of modules found on the directory path.

Parameters:
path The directory's path to search for modules
recursive Iterate recursively on the path
cb Callback function to call, if the return value of the callback is zero it won't be added to the list, if it is one, it will.
data Data passed to the callback function

References eina_array_new(), and eina_file_dir_list().

EAPI void eina_module_list_load ( Eina_Array array  ) 

Load every module on the list of modules.

Parameters:
list The list of modules

References EINA_ARRAY_ITER_NEXT, and eina_module_load().