summaryrefslogtreecommitdiff
path: root/ext/sqlite/php_sqlite.h
blob: 6639a4b595e453d0e17ca74d01cfc7f133271fec (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
/*
   +----------------------------------------------------------------------+
   | PHP Version 5                                                        |
   +----------------------------------------------------------------------+
   | Copyright (c) 1997-2008 The PHP Group                                |
   +----------------------------------------------------------------------+
   | This source file is subject to version 3.01 of the PHP license,      |
   | that is bundled with this package in the file LICENSE, and is        |
   | available through the world-wide-web at the following url:           |
   | http://www.php.net/license/3_01.txt                                  |
   | If you did not receive a copy of the PHP license and are unable to   |
   | obtain it through the world-wide-web, please send a note to          |
   | license@php.net so we can mail you a copy immediately.               |
   +----------------------------------------------------------------------+
   | Authors: Wez Furlong <wez@thebrainroom.com>                          |
   |          Tal Peer <tal@php.net>                                      |
   |          Marcus Boerger <helly@php.net>                              |
   +----------------------------------------------------------------------+

   $Id$ 
*/

#ifndef PHP_SQLITE_H
#define PHP_SQLITE_H

extern zend_module_entry sqlite_module_entry;
#define phpext_sqlite_ptr &sqlite_module_entry

#ifdef PHP_WIN32
#define PHP_SQLITE_API __declspec(dllexport)
#else
#define PHP_SQLITE_API
#endif

#ifdef ZTS
#include "TSRM.h"
#endif

PHP_MINIT_FUNCTION(sqlite);
PHP_MSHUTDOWN_FUNCTION(sqlite);
PHP_RSHUTDOWN_FUNCTION(sqlite);
PHP_MINFO_FUNCTION(sqlite);

PHP_FUNCTION(sqlite_open);
PHP_FUNCTION(sqlite_popen);
PHP_FUNCTION(sqlite_close);
PHP_FUNCTION(sqlite_query);
PHP_FUNCTION(sqlite_exec);
PHP_FUNCTION(sqlite_unbuffered_query);
PHP_FUNCTION(sqlite_array_query);
PHP_FUNCTION(sqlite_single_query);

PHP_FUNCTION(sqlite_fetch_array);
PHP_FUNCTION(sqlite_fetch_object);
PHP_FUNCTION(sqlite_fetch_single);
PHP_FUNCTION(sqlite_fetch_all);
PHP_FUNCTION(sqlite_current);
PHP_FUNCTION(sqlite_column);

PHP_FUNCTION(sqlite_num_rows);
PHP_FUNCTION(sqlite_num_fields);
PHP_FUNCTION(sqlite_field_name);
PHP_FUNCTION(sqlite_seek);
PHP_FUNCTION(sqlite_rewind);
PHP_FUNCTION(sqlite_next);
PHP_FUNCTION(sqlite_prev);
PHP_FUNCTION(sqlite_key);

PHP_FUNCTION(sqlite_valid);
PHP_FUNCTION(sqlite_has_prev);

PHP_FUNCTION(sqlite_libversion);
PHP_FUNCTION(sqlite_libencoding);

PHP_FUNCTION(sqlite_changes);
PHP_FUNCTION(sqlite_last_insert_rowid);

PHP_FUNCTION(sqlite_escape_string);

PHP_FUNCTION(sqlite_busy_timeout);

PHP_FUNCTION(sqlite_last_error);
PHP_FUNCTION(sqlite_error_string);

PHP_FUNCTION(sqlite_create_aggregate);
PHP_FUNCTION(sqlite_create_function);
PHP_FUNCTION(sqlite_udf_decode_binary);
PHP_FUNCTION(sqlite_udf_encode_binary);

PHP_FUNCTION(sqlite_factory);

PHP_FUNCTION(sqlite_fetch_column_types);

ZEND_BEGIN_MODULE_GLOBALS(sqlite)
	 long assoc_case;
ZEND_END_MODULE_GLOBALS(sqlite)

#ifdef ZTS
#define SQLITE_G(v) TSRMG(sqlite_globals_id, zend_sqlite_globals *, v)
#else
#define SQLITE_G(v) (sqlite_globals.v)
#endif

#endif


/*
 * Local variables:
 * tab-width: 4
 * c-basic-offset: 4
 * indent-tabs-mode: t
 * End:
 */