1 /*
2   +----------------------------------------------------------------------+
3   | Yet Another Framework                                                |
4   +----------------------------------------------------------------------+
5   | This source file is subject to version 3.01 of the PHP license,      |
6   | that is bundled with this package in the file LICENSE, and is        |
7   | available through the world-wide-web at the following url:           |
8   | http://www.php.net/license/3_01.txt                                  |
9   | If you did not receive a copy of the PHP license and are unable to   |
10   | obtain it through the world-wide-web, please send a note to          |
11   | license@php.net so we can mail you a copy immediately.               |
12   +----------------------------------------------------------------------+
13   | Author: Xinchen Hui  <laruence@php.net>                              |
14   +----------------------------------------------------------------------+
15 */
16 
17 #ifndef YAF_ROUTER_REGEX_H
18 #define YAF_ROUTER_REGEX_H
19 
20 typedef struct {
21 	zend_object  std;
22 	zend_string *match;
23 	zend_array  *router;
24 	zend_array  *map;
25 	zend_array  *verify;
26 	zend_string *reverse;
27 	zend_array  *properties;
28 } yaf_route_regex_object;
29 
30 #define Z_YAFROUTEREGEXOBJ(zv)    ((yaf_route_regex_object*)(Z_OBJ(zv)))
31 #define Z_YAFROUTEREGEXOBJ_P(zv)  Z_YAFROUTEREGEXOBJ(*zv)
32 
33 extern zend_class_entry *yaf_route_regex_ce;
34 
35 void yaf_route_regex_instance(yaf_route_t *route, zend_string *match, zval *router, zval *map, zval *verify, zend_string *reverse);
36 int yaf_route_regex_route(yaf_route_t *route, yaf_request_t *req);
37 
38 YAF_STARTUP_FUNCTION(route_regex);
39 
40 #endif
41 /*
42  * Local variables:
43  * tab-width: 4
44  * c-basic-offset: 4
45  * End:
46  * vim600: noet sw=4 ts=4 fdm=marker
47  * vim<600: noet sw=4 ts=4
48  */
49