2 #ifndef SERV_EXTENSIONS_H
3 #define SERV_EXTENSIONS_H
8 * This is where we declare all of the server extensions we have.
9 * We'll probably start moving these to a more sane location in the near
10 * future. For now, this just shuts up the compiler.
12 //void serv_calendar_destroy(void);
13 //char *serv_test_init(void);
14 //char *serv_postfix_tcpdict(void);
18 typedef void (*CtdlDbgFunction) (const int);
23 * ServiceFunctionHook extensions are used for hooks which implement various
24 * protocols (either on TCP or on unix domain sockets) directly in the Citadel server.
26 typedef struct ServiceFunctionHook ServiceFunctionHook;
27 struct ServiceFunctionHook {
28 ServiceFunctionHook *next;
31 void (*h_greeting_function) (void) ;
32 void (*h_command_function) (void) ;
33 void (*h_async_function) (void) ;
35 const char* ServiceName; /* this is just for debugging and logging purposes. */
37 extern ServiceFunctionHook *ServiceHookTable;
39 typedef struct CleanupFunctionHook CleanupFunctionHook;
40 struct CleanupFunctionHook {
41 CleanupFunctionHook *next;
42 void (*h_function_pointer) (void);
44 extern CleanupFunctionHook *CleanupHookTable;
47 void initialize_server_extensions(void);
48 int DLoader_Exec_Cmd(char *cmdbuf);
49 char *Dynamic_Module_Init(void);
51 void CtdlDestroySessionHooks(void);
52 void PerformSessionHooks(int EventType);
54 void CtdlDestroyUserHooks(void);
55 void PerformUserHooks(struct ctdluser *usbuf, int EventType);
57 int PerformXmsgHooks(char *, char *, char *, char *);
58 void CtdlDestroyXmsgHooks(void);
62 void CtdlDestroyMessageHook(void);
63 int PerformMessageHooks(struct CtdlMessage *, int EventType);
66 void CtdlDestroyNetprocHooks(void);
67 int PerformNetprocHooks(struct CtdlMessage *, char *);
69 void CtdlDestroyRoomHooks(void);
70 int PerformRoomHooks(struct ctdlroom *);
73 void CtdlDestroyDeleteHooks(void);
74 void PerformDeleteHooks(char *, long);
77 void CtdlDestroyCleanupHooks(void);
79 void CtdlDestroyProtoHooks(void);
81 void CtdlDestroyServiceHook(void);
83 void CtdlDestroySearchHooks(void);
85 void CtdlDestroyFixedOutputHooks(void);
86 int PerformFixedOutputHooks(char *, char *, int);
88 void CtdlRegisterDebugFlagHook(const char *Name, long len, CtdlDbgFunction F, const int *);
89 void CtdlSetDebugLogFacilities(const char **Str, long n);
90 void CtdlDestroyDebugTable(void);
92 #endif /* SERV_EXTENSIONS_H */