2
+----------------------------------------------------------------------+
4
+----------------------------------------------------------------------+
5
| Copyright (c) 1997-2007 The PHP Group |
6
+----------------------------------------------------------------------+
7
| This source file is subject to version 3.0 of the PHP license, |
8
| that is bundled with this package in the file LICENSE, and is |
9
| available through the world-wide-web at the following url: |
10
| http://www.php.net/license/3_0.txt. |
11
| If you did not receive a copy of the PHP license and are unable to |
12
| obtain it through the world-wide-web, please send a note to |
13
| license@php.net so we can mail you a copy immediately. |
14
+----------------------------------------------------------------------+
15
| Authors: Antony Dovgal <tony2001@phpclub.net> |
16
| Mikael Johansson <mikael AT synd DOT info> |
17
+----------------------------------------------------------------------+
20
/* $Id: php_memcache.h 310126 2011-04-11 04:19:29Z hradtke $ */
22
#ifndef PHP_MEMCACHE_H
23
#define PHP_MEMCACHE_H
25
extern zend_module_entry memcache_module_entry;
26
#define phpext_memcache_ptr &memcache_module_entry
29
#define PHP_MEMCACHE_API __declspec(dllexport)
31
#define PHP_MEMCACHE_API
34
#include "memcache_pool.h"
36
PHP_MINIT_FUNCTION(memcache);
37
PHP_MSHUTDOWN_FUNCTION(memcache);
38
PHP_MINFO_FUNCTION(memcache);
40
PHP_NAMED_FUNCTION(zif_memcache_pool_connect);
41
PHP_NAMED_FUNCTION(zif_memcache_pool_addserver);
42
PHP_NAMED_FUNCTION(zif_memcache_pool_findserver);
44
PHP_FUNCTION(memcache_connect);
45
PHP_FUNCTION(memcache_pconnect);
46
PHP_FUNCTION(memcache_add_server);
47
PHP_FUNCTION(memcache_set_server_params);
48
PHP_FUNCTION(memcache_set_failure_callback);
49
PHP_FUNCTION(memcache_get_server_status);
50
PHP_FUNCTION(memcache_get_version);
51
PHP_FUNCTION(memcache_add);
52
PHP_FUNCTION(memcache_set);
53
PHP_FUNCTION(memcache_replace);
54
PHP_FUNCTION(memcache_cas);
55
PHP_FUNCTION(memcache_append);
56
PHP_FUNCTION(memcache_prepend);
57
PHP_FUNCTION(memcache_get);
58
PHP_FUNCTION(memcache_delete);
59
PHP_FUNCTION(memcache_debug);
60
PHP_FUNCTION(memcache_get_stats);
61
PHP_FUNCTION(memcache_get_extended_stats);
62
PHP_FUNCTION(memcache_set_compress_threshold);
63
PHP_FUNCTION(memcache_increment);
64
PHP_FUNCTION(memcache_decrement);
65
PHP_FUNCTION(memcache_close);
66
PHP_FUNCTION(memcache_flush);
68
#define PHP_MEMCACHE_VERSION "3.0.7"
70
#define MMC_DEFAULT_TIMEOUT 1 /* seconds */
71
#define MMC_DEFAULT_RETRY 15 /* retry failed server after x seconds */
72
#define MMC_DEFAULT_CACHEDUMP_LIMIT 100 /* number of entries */
74
#if (PHP_MAJOR_VERSION == 5) && (PHP_MINOR_VERSION >= 3)
75
# define IS_CALLABLE(cb_zv, flags, cb_sp) zend_is_callable((cb_zv), (flags), (cb_sp) TSRMLS_CC)
77
# define IS_CALLABLE(cb_zv, flags, cb_sp) zend_is_callable((cb_zv), (flags), (cb_sp))
80
/* internal functions */
81
mmc_t *mmc_find_persistent(const char *, int, unsigned short, unsigned short, double, int TSRMLS_DC);
82
int mmc_value_handler_single(const char *, unsigned int, zval *, unsigned int, unsigned long, void * TSRMLS_DC);
83
int mmc_value_handler_multi(const char *, unsigned int, zval *, unsigned int, unsigned long, void * TSRMLS_DC);
84
int mmc_stored_handler(mmc_t *, mmc_request_t *, int, const char *, unsigned int, void * TSRMLS_DC);
85
int mmc_numeric_response_handler(mmc_t *, mmc_request_t *, int, const char *, unsigned int, void * TSRMLS_DC);
87
/* session handler struct */
88
#if HAVE_MEMCACHE_SESSION
89
#include "ext/session/php_session.h"
91
extern ps_module ps_mod_memcache;
92
#define ps_memcache_ptr &ps_mod_memcache
97
#endif /* PHP_MEMCACHE_H */
104
* vim600: noet sw=4 ts=4 fdm=marker
105
* vim<600: noet sw=4 ts=4