blob: 174a8d092ebdca4a85bbf9b25541294579b1323f (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
|
#ifndef foomodulehfoo
#define foomodulehfoo
#include <inttypes.h>
#include <ltdl.h>
#include "core.h"
struct pa_module {
struct pa_core *core;
char *name, *argument;
uint32_t index;
lt_dlhandle dl;
int (*init)(struct pa_core *c, struct pa_module*m);
void (*done)(struct pa_core *c, struct pa_module*m);
void *userdata;
};
struct pa_module* pa_module_load(struct pa_core *c, const char *name, const char*argument);
void pa_module_unload(struct pa_core *c, struct pa_module *m);
void pa_module_unload_by_index(struct pa_core *c, uint32_t index);
void pa_module_unload_all(struct pa_core *c);
void pa_module_unload_request(struct pa_core *c, struct pa_module *m);
/* These to following prototypes are for module entrypoints and not implemented by the core */
int pa_module_init(struct pa_core *c, struct pa_module*m);
void pa_module_done(struct pa_core *c, struct pa_module*m);
#endif
|