1999-04-08 02:10:10 +08:00
|
|
|
/*
|
|
|
|
+----------------------------------------------------------------------+
|
|
|
|
| Zend Engine |
|
|
|
|
+----------------------------------------------------------------------+
|
2000-03-06 13:26:39 +08:00
|
|
|
| Copyright (c) 1998-2000 Zend Technologies Ltd. (http://www.zend.com) |
|
1999-04-08 02:10:10 +08:00
|
|
|
+----------------------------------------------------------------------+
|
2000-03-06 13:26:39 +08:00
|
|
|
| This source file is subject to version 0.92 of the Zend license, |
|
1999-07-16 22:58:16 +08:00
|
|
|
| that is bundled with this package in the file LICENSE, and is |
|
|
|
|
| available at through the world-wide-web at |
|
2000-03-06 13:26:39 +08:00
|
|
|
| http://www.zend.com/license/0_92.txt. |
|
1999-07-16 22:58:16 +08:00
|
|
|
| If you did not receive a copy of the Zend license and are unable to |
|
|
|
|
| obtain it through the world-wide-web, please send a note to |
|
|
|
|
| license@zend.com so we can mail you a copy immediately. |
|
1999-04-08 02:10:10 +08:00
|
|
|
+----------------------------------------------------------------------+
|
|
|
|
| Authors: Andi Gutmans <andi@zend.com> |
|
|
|
|
| Zeev Suraski <zeev@zend.com> |
|
|
|
|
+----------------------------------------------------------------------+
|
|
|
|
*/
|
|
|
|
|
1999-07-16 22:58:16 +08:00
|
|
|
|
1999-04-08 02:10:10 +08:00
|
|
|
#ifndef _ZEND_EXTENSIONS_H
|
|
|
|
#define _ZEND_EXTENSIONS_H
|
|
|
|
|
|
|
|
#include "zend_compile.h"
|
|
|
|
|
2000-03-07 03:25:08 +08:00
|
|
|
#define ZEND_EXTENSION_API_NO 20000306
|
1999-04-08 02:10:10 +08:00
|
|
|
|
1999-05-23 00:10:51 +08:00
|
|
|
typedef struct _zend_extension_version_info {
|
1999-04-08 02:10:10 +08:00
|
|
|
int zend_extension_api_no;
|
|
|
|
char *required_zend_version;
|
|
|
|
unsigned char thread_safe;
|
1999-04-27 19:00:59 +08:00
|
|
|
unsigned char debug;
|
1999-04-08 02:10:10 +08:00
|
|
|
} zend_extension_version_info;
|
|
|
|
|
|
|
|
|
|
|
|
typedef struct _zend_extension zend_extension;
|
|
|
|
|
|
|
|
struct _zend_extension {
|
|
|
|
char *name;
|
|
|
|
char *version;
|
|
|
|
char *author;
|
|
|
|
char *URL;
|
|
|
|
char *copyright;
|
|
|
|
|
1999-04-20 05:39:18 +08:00
|
|
|
int (*startup)(zend_extension *extension);
|
1999-04-08 02:10:10 +08:00
|
|
|
void (*shutdown)(zend_extension *extension);
|
1999-12-23 03:21:15 +08:00
|
|
|
void (*activate)();
|
|
|
|
void (*deactivate)();
|
1999-04-08 02:10:10 +08:00
|
|
|
|
|
|
|
void (*op_array_handler)(zend_op_array *op_array);
|
|
|
|
|
|
|
|
void (*statement_handler)(zend_op_array *op_array);
|
|
|
|
void (*fcall_begin_handler)(zend_op_array *op_array);
|
|
|
|
void (*fcall_end_handler)(zend_op_array *op_array);
|
|
|
|
|
|
|
|
void (*op_array_ctor)(void **resource);
|
|
|
|
void (*op_array_dtor)(void **resource);
|
|
|
|
|
|
|
|
void *reserved1;
|
|
|
|
void *reserved2;
|
|
|
|
void *reserved3;
|
|
|
|
void *reserved4;
|
|
|
|
void *reserved5;
|
|
|
|
void *reserved6;
|
|
|
|
void *reserved7;
|
|
|
|
void *reserved8;
|
|
|
|
|
|
|
|
DL_HANDLE handle;
|
|
|
|
int resource_number;
|
|
|
|
};
|
|
|
|
|
|
|
|
|
1999-12-02 06:55:20 +08:00
|
|
|
ZEND_API int zend_get_resource_handle(zend_extension *extension);
|
1999-04-08 02:10:10 +08:00
|
|
|
|
|
|
|
#ifdef ZTS
|
|
|
|
#define ZTS_V 1
|
|
|
|
#else
|
|
|
|
#define ZTS_V 0
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
|
|
#define ZEND_EXTENSION() \
|
1999-08-29 05:43:24 +08:00
|
|
|
ZEND_EXT_API zend_extension_version_info extension_version_info = { ZEND_EXTENSION_API_NO, "0.90", ZTS_V, ZEND_DEBUG }
|
1999-04-08 02:10:10 +08:00
|
|
|
|
|
|
|
#define STANDARD_ZEND_EXTENSION_PROPERTIES NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, -1
|
|
|
|
|
|
|
|
|
|
|
|
ZEND_API extern zend_llist zend_extensions;
|
|
|
|
|
|
|
|
void zend_extension_dtor(zend_extension *extension);
|
|
|
|
int zend_load_extension(char *path);
|
|
|
|
int zend_load_extensions(char **extension_paths);
|
|
|
|
void zend_append_version_info(zend_extension *extension);
|
1999-12-02 06:55:20 +08:00
|
|
|
void zend_shutdown_extensions(void);
|
1999-04-08 02:10:10 +08:00
|
|
|
|
|
|
|
#endif /* _ZEND_EXTENSIONS_H */
|