mirror of
https://github.com/sqlite/sqlite.git
synced 2025-07-29 08:01:23 +03:00
Add file sqlite3rtree.h.
FossilOrigin-Name: e1d9ffce0f84469eeb926f50030cb772de98a652
This commit is contained in:
26
ext/rtree/sqlite3rtree.h
Normal file
26
ext/rtree/sqlite3rtree.h
Normal file
@ -0,0 +1,26 @@
|
||||
|
||||
#include <sqlite3.h>
|
||||
|
||||
typedef struct RtreeGeometry RtreeGeometry;
|
||||
|
||||
struct RtreeGeometry {
|
||||
void *pContext; /* Copy of pContext passed to s_r_g_c() */
|
||||
int nParam; /* Size of array aParam[] */
|
||||
double *aParam; /* Parameters passed to SQL geom function */
|
||||
void *pUser; /* Callback implementation user data */
|
||||
void (*xDelUser)(void *); /* Called by SQLite to clean up pUser */
|
||||
};
|
||||
|
||||
/*
|
||||
** Register a geometry callback named zGeom that can be used as part of an
|
||||
** R-Tree geometry query as follows:
|
||||
**
|
||||
** SELECT ... FROM <rtree> WHERE <rtree> MATCH $zGeom(... params ...)
|
||||
*/
|
||||
int sqlite3_rtree_geometry_callback(
|
||||
sqlite3 *db,
|
||||
const char *zGeom,
|
||||
int (*xGeom)(RtreeGeometry *, int nCoord, double *aCoord, int *piResOut),
|
||||
void *pContext
|
||||
);
|
||||
|
Reference in New Issue
Block a user