mirror of
https://github.com/sqlite/sqlite.git
synced 2025-11-19 21:43:15 +03:00
Add API functions sqlite3_open_varargs(), sqlite3_open16_varargs() and
sqlite3_complete16(). (CVS 1479) FossilOrigin-Name: 203af2b2e3a25f4fe0e128e350c21834cad0bd7f
This commit is contained in:
@@ -12,7 +12,7 @@
|
||||
** This header file defines the interface that the SQLite library
|
||||
** presents to client programs.
|
||||
**
|
||||
** @(#) $Id: sqlite.h.in,v 1.84 2004/05/27 09:28:43 danielk1977 Exp $
|
||||
** @(#) $Id: sqlite.h.in,v 1.85 2004/05/27 23:56:16 danielk1977 Exp $
|
||||
*/
|
||||
#ifndef _SQLITE_H_
|
||||
#define _SQLITE_H_
|
||||
@@ -229,14 +229,18 @@ const char *sqlite3_error_string(int);
|
||||
void sqlite3_interrupt(sqlite*);
|
||||
|
||||
|
||||
/* This function returns true if the given input string comprises
|
||||
** one or more complete SQL statements.
|
||||
/* These functions return true if the given input string comprises
|
||||
** one or more complete SQL statements. For the sqlite3_complete() call,
|
||||
** the parameter must be a nul-terminated UTF-8 string. For
|
||||
** sqlite3_complete16(), a nul-terminated machine byte order UTF-16 string
|
||||
** is required.
|
||||
**
|
||||
** The algorithm is simple. If the last token other than spaces
|
||||
** and comments is a semicolon, then return true. otherwise return
|
||||
** false.
|
||||
*/
|
||||
int sqlite3_complete(const char *sql);
|
||||
int sqlite3_complete16(const void *sql);
|
||||
|
||||
/*
|
||||
** This routine identifies a callback function that is invoked
|
||||
@@ -523,6 +527,23 @@ int sqlite3_open16(
|
||||
const char **args /* Null terminated array of option strings */
|
||||
);
|
||||
|
||||
/*
|
||||
** The following two functions are identical to sqlite3_open() and
|
||||
** sqlite3_open16(), except that any option strings are specified as the
|
||||
** third and subsequent arguments, instead of as an array. The final
|
||||
** argument to either of the following two functions must be a NULL.
|
||||
*/
|
||||
int sqlite3_open_vararg(
|
||||
const char *filename, /* Database filename (UTF-8) */
|
||||
sqlite3 **ppDb, /* OUT: SQLite db handle */
|
||||
... /* Option strings */
|
||||
);
|
||||
int sqlite3_open16_vararg(
|
||||
const void *filename, /* Database filename (UTF-16) */
|
||||
sqlite3 **ppDb, /* OUT: SQLite db handle */
|
||||
... /* Option strings */
|
||||
);
|
||||
|
||||
/*
|
||||
** Return the error code for the most recent sqlite3_* API call associated
|
||||
** with sqlite3 handle 'db'. SQLITE_OK is returned if the most recent
|
||||
|
||||
Reference in New Issue
Block a user