Subversion Repositories Tewi

Rev

Rev 314 | Rev 367 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 314 Rev 315
Line 1... Line 1...
1
/* $Id: tw_module.h 314 2024-10-14 07:37:04Z nishi $ */
1
/* $Id: tw_module.h 315 2024-10-14 10:01:02Z nishi $ */
2
 
2
 
3
#ifndef __TW_MODULE_H__
3
#ifndef __TW_MODULE_H__
4
#define __TW_MODULE_H__
4
#define __TW_MODULE_H__
5
 
5
 
6
#ifdef __cplusplus
6
#ifdef __cplusplus
Line 13... Line 13...
13
#if defined(__OS2__)
13
#if defined(__OS2__)
14
#define INCL_DOSMODULEMGR
14
#define INCL_DOSMODULEMGR
15
#define INCL_DOSERRORS
15
#define INCL_DOSERRORS
16
#include <os2.h>
16
#include <os2.h>
17
#define MODULE_DECL __export APIENTRY
17
#define MODULE_DECL __export APIENTRY
-
 
18
#elif defined(__WATCOMC__)
-
 
19
#define MODULE_DECL __export
18
#else
20
#else
19
#define MODULE_DECL
21
#define MODULE_DECL
20
#endif
22
#endif
21
 
23
 
22
struct tw_tool {
24
struct tw_tool {
Line 44... Line 46...
44
 
46
 
45
#define TW_CONFIG_PARSED _TW_CONFIG_PARSED
47
#define TW_CONFIG_PARSED _TW_CONFIG_PARSED
46
#define TW_CONFIG_NOTME _TW_CONFIG_NOTME
48
#define TW_CONFIG_NOTME _TW_CONFIG_NOTME
47
#define TW_CONFIG_ERROR _TW_CONFIG_ERROR
49
#define TW_CONFIG_ERROR _TW_CONFIG_ERROR
48
 
50
 
49
typedef int (MODULE_DECL *tw_mod_init_t)(struct tw_config* config, struct tw_tool* tools);
51
typedef int(MODULE_DECL* tw_mod_init_t)(struct tw_config* config, struct tw_tool* tools);
50
typedef int (MODULE_DECL *tw_mod_request_t)(struct tw_tool* tools, struct tw_http_request* req, struct tw_http_response* res);
52
typedef int(MODULE_DECL* tw_mod_request_t)(struct tw_tool* tools, struct tw_http_request* req, struct tw_http_response* res);
51
typedef int (MODULE_DECL *tw_mod_config_t)(struct tw_tool* tools, char** argv, int argc);
53
typedef int(MODULE_DECL* tw_mod_config_t)(struct tw_tool* tools, char** argv, int argc);
52
 
54
 
53
#ifdef SOURCE
55
#ifdef SOURCE
54
void* tw_module_load(const char* path);
56
void* tw_module_load(const char* path);
55
void* tw_module_symbol(void* mod, const char* sym);
57
void* tw_module_symbol(void* mod, const char* sym);
56
void tw_init_tools(struct tw_tool* tools);
58
void tw_init_tools(struct tw_tool* tools);