-
Notifications
You must be signed in to change notification settings - Fork 1
/
sophia.h
62 lines (54 loc) · 1.23 KB
/
sophia.h
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
#ifndef SOPHIA_H_
#define SOPHIA_H_
#ifdef C2NIM
# dynlib libname
# cdecl
# prefix sp_
# if defined(windows)
# define libname "libsophia.dll"
# elif defined(macosx)
# define libname "libsophia.dylib"
# else
# define libname "libsophia.so"
# endif
#mangle uint16_t uint16
#mangle uint64_t uint64
#mangle int64_t int64
#endif
/*
* sophia database
* sphia.org
*
* Copyright (c) Dmitry Simonenko
* BSD License
*/
#ifdef __cplusplus
extern "C" {
#endif
#include <stdlib.h>
#include <stdint.h>
void *sp_env(void);
void *sp_document(void*);
int sp_setstring(void*, const char*, const void*, int);
int sp_setint(void*, const char*, int64_t);
void *sp_getobject(void*, const char*);
void *sp_getstring(void*, const char*, int*);
int64_t sp_getint(void*, const char*);
int sp_open(void*);
int sp_destroy(void*);
int sp_error(void*);
int sp_service(void*);
void *sp_poll(void*);
int sp_drop(void*);
int sp_set(void*, void*);
int sp_upsert(void*, void*);
int sp_delete(void*, void*);
void *sp_get(void*, void*);
void *sp_cursor(void*);
void *sp_begin(void*);
int sp_prepare(void*);
int sp_commit(void*);
#ifdef __cplusplus
}
#endif
#endif