2 +----------------------------------------------------------------------+
4 +----------------------------------------------------------------------+
5 | This source file is subject to version 3.0 of the PHP license, that |
6 | is bundled with this package in the file LICENSE, and is available |
7 | through the world-wide-web at http://www.php.net/license/3_0.txt. |
8 | If you did not receive a copy of the PHP license and are unable to |
9 | obtain it through the world-wide-web, please send a note to |
10 | license@php.net so we can mail you a copy immediately. |
11 +----------------------------------------------------------------------+
12 | Copyright (c) 2004-2005 Michael Wallner <mike@php.net> |
13 +----------------------------------------------------------------------+
18 #ifndef PHP_HTTP_CACHE_API_H
19 #define PHP_HTTP_CACHE_API_H
21 #include "php_http_std_defs.h"
22 #include "php_http_api.h"
23 #include "php_http_send_api.h"
25 #define http_cache_exit(t, e) http_cache_exit_ex((t), (e), 1)
26 #define http_cache_exit_ex(t, e, f) _http_cache_exit_ex((t), (e), (f) TSRMLS_CC)
27 extern STATUS
_http_cache_exit_ex(char *cache_token
, zend_bool etag
, zend_bool free_token TSRMLS_DC
);
29 #define http_etag(p, l, m) _http_etag((p), (l), (m) TSRMLS_CC)
30 PHP_HTTP_API
char *_http_etag(const void *data_ptr
, size_t data_len
, http_send_mode data_mode TSRMLS_DC
);
32 #define http_last_modified(p, m) _http_last_modified((p), (m) TSRMLS_CC)
33 PHP_HTTP_API
time_t _http_last_modified(const void *data_ptr
, http_send_mode data_mode TSRMLS_DC
);
35 #define http_match_last_modified(entry, modified) _http_match_last_modified_ex((entry), (modified), 1 TSRMLS_CC)
36 #define http_match_last_modified_ex(entry, modified, ep) _http_match_last_modified_ex((entry), (modified), (ep) TSRMLS_CC)
37 PHP_HTTP_API zend_bool
_http_match_last_modified_ex(const char *entry
, time_t t
, zend_bool enforce_presence TSRMLS_DC
);
39 #define http_match_etag(entry, etag) _http_match_etag_ex((entry), (etag), 1 TSRMLS_CC)
40 #define http_match_etag_ex(entry, etag, ep) _http_match_etag_ex((entry), (etag), (ep) TSRMLS_CC)
41 PHP_HTTP_API zend_bool
_http_match_etag_ex(const char *entry
, const char *etag
, zend_bool enforce_presence TSRMLS_DC
);
43 #define http_cache_last_modified(l, s, cc, ccl) _http_cache_last_modified((l), (s), (cc), (ccl) TSRMLS_CC)
44 PHP_HTTP_API STATUS
_http_cache_last_modified(time_t last_modified
, time_t send_modified
, const char *cache_control
, size_t cc_len TSRMLS_DC
);
46 #define http_cache_etag(e, el, cc, ccl) _http_cache_etag((e), (el), (cc), (ccl) TSRMLS_CC)
47 PHP_HTTP_API STATUS
_http_cache_etag(const char *etag
, size_t etag_len
, const char *cache_control
, size_t cc_len TSRMLS_DC
);
49 #define http_ob_etaghandler(o, l, ho, hl, m) _http_ob_etaghandler((o), (l), (ho), (hl), (m) TSRMLS_CC)
50 PHP_HTTP_API
void _http_ob_etaghandler(char *output
, uint output_len
, char **handled_output
, uint
*handled_output_len
, int mode TSRMLS_DC
);
59 * vim600: noet sw=4 ts=4 fdm=marker
60 * vim<600: noet sw=4 ts=4