2
#include <mysql/services.h>
3
#include <mysql/service_my_snprintf.h>
4
extern struct my_snprintf_service_st {
5
size_t (*my_snprintf_type)(char*, size_t, const char*, ...);
6
size_t (*my_vsnprintf_type)(char *, size_t, const char*, va_list);
7
} *my_snprintf_service;
8
size_t my_snprintf(char* to, size_t n, const char* fmt, ...);
9
size_t my_vsnprintf(char *to, size_t n, const char* fmt, va_list ap);
10
#include <mysql/service_thd_alloc.h>
11
struct st_mysql_lex_string
16
typedef struct st_mysql_lex_string MYSQL_LEX_STRING;
17
extern struct thd_alloc_service_st {
18
void *(*thd_alloc_func)(void*, unsigned int);
19
void *(*thd_calloc_func)(void*, unsigned int);
20
char *(*thd_strdup_func)(void*, const char *);
21
char *(*thd_strmake_func)(void*, const char *, unsigned int);
22
void *(*thd_memdup_func)(void*, const void*, unsigned int);
23
MYSQL_LEX_STRING *(*thd_make_lex_string_func)(void*, MYSQL_LEX_STRING *,
24
const char *, unsigned int, int);
26
void *thd_alloc(void* thd, unsigned int size);
27
void *thd_calloc(void* thd, unsigned int size);
28
char *thd_strdup(void* thd, const char *str);
29
char *thd_strmake(void* thd, const char *str, unsigned int size);
30
void *thd_memdup(void* thd, const void* str, unsigned int size);
31
MYSQL_LEX_STRING *thd_make_lex_string(void* thd, MYSQL_LEX_STRING *lex_str,
32
const char *str, unsigned int size,
33
int allocate_lex_string);
34
#include <mysql/service_thd_wait.h>
35
typedef enum _thd_wait_type_e {
39
THD_WAIT_GLOBAL_LOCK= 4,
40
THD_WAIT_META_DATA_LOCK= 5,
41
THD_WAIT_TABLE_LOCK= 6,
42
THD_WAIT_USER_LOCK= 7,
44
THD_WAIT_GROUP_COMMIT= 9,
48
extern struct thd_wait_service_st {
49
void (*thd_wait_begin_func)(void*, int);
50
void (*thd_wait_end_func)(void*);
52
void thd_wait_begin(void* thd, int wait_type);
53
void thd_wait_end(void* thd);
54
#include <mysql/service_thread_scheduler.h>
55
struct scheduler_functions;
56
extern struct my_thread_scheduler_service {
57
int (*set)(struct scheduler_functions *scheduler);
59
} *my_thread_scheduler_service;
60
int my_thread_scheduler_set(struct scheduler_functions *scheduler);
61
int my_thread_scheduler_reset();
62
#include <mysql/service_progress_report.h>
63
extern struct progress_report_service_st {
64
void (*thd_progress_init_func)(void* thd, unsigned int max_stage);
65
void (*thd_progress_report_func)(void* thd,
66
unsigned long long progress,
67
unsigned long long max_progress);
68
void (*thd_progress_next_stage_func)(void* thd);
69
void (*thd_progress_end_func)(void* thd);
70
const char *(*set_thd_proc_info_func)(void*, const char *info,
74
} *progress_report_service;
75
void thd_progress_init(void* thd, unsigned int max_stage);
76
void thd_progress_report(void* thd,
77
unsigned long long progress,
78
unsigned long long max_progress);
79
void thd_progress_next_stage(void* thd);
80
void thd_progress_end(void* thd);
81
const char *set_thd_proc_info(void*, const char * info, const char *func,
82
const char *file, unsigned int line);
83
#include <mysql/service_debug_sync.h>
84
extern void (*debug_sync_C_callback_ptr)(void*, const char *, size_t);
85
#include <mysql/service_kill_statement.h>
86
enum thd_kill_levels {
91
extern struct kill_statement_service_st {
92
enum thd_kill_levels (*thd_kill_level_func)(const void*);
93
} *thd_kill_statement_service;
94
enum thd_kill_levels thd_kill_level(const void*);
101
typedef struct st_mysql_xid MYSQL_XID;
102
enum enum_mysql_show_type
104
SHOW_UNDEF, SHOW_BOOL, SHOW_UINT, SHOW_ULONG,
105
SHOW_ULONGLONG, SHOW_CHAR, SHOW_CHAR_PTR,
106
SHOW_ARRAY, SHOW_FUNC, SHOW_DOUBLE,
107
SHOW_SINT, SHOW_SLONG, SHOW_SLONGLONG,
110
struct st_mysql_show_var {
113
enum enum_mysql_show_type type;
115
typedef int (*mysql_show_var_func)(void*, struct st_mysql_show_var*, char *);
116
struct st_mysql_sys_var;
117
struct st_mysql_value;
118
typedef int (*mysql_var_check_func)(void* thd,
119
struct st_mysql_sys_var *var,
120
void *save, struct st_mysql_value *value);
121
typedef void (*mysql_var_update_func)(void* thd,
122
struct st_mysql_sys_var *var,
123
void *var_ptr, const void *save);
124
struct st_mysql_plugin
133
int (*deinit)(void *);
134
unsigned int version;
135
struct st_mysql_show_var *status_vars;
136
struct st_mysql_sys_var **system_vars;
140
struct st_maria_plugin
149
int (*deinit)(void *);
150
unsigned int version;
151
struct st_mysql_show_var *status_vars;
152
struct st_mysql_sys_var **system_vars;
153
const char *version_info;
154
unsigned int maturity;
156
#include "plugin_ftparser.h"
157
struct st_mysql_daemon
159
int interface_version;
161
struct st_mysql_information_schema
163
int interface_version;
165
struct st_mysql_storage_engine
167
int interface_version;
170
struct Mysql_replication {
171
int interface_version;
173
struct st_mysql_value
175
int (*value_type)(struct st_mysql_value *);
176
const char *(*val_str)(struct st_mysql_value *, char *buffer, int *length);
177
int (*val_real)(struct st_mysql_value *, double *realbuf);
178
int (*val_int)(struct st_mysql_value *, long long *intbuf);
179
int (*is_unsigned)(struct st_mysql_value *);
181
int thd_in_lock_tables(const void* thd);
182
int thd_tablespace_op(const void* thd);
183
long long thd_test_options(const void* thd, long long test_options);
184
int thd_sql_command(const void* thd);
185
void **thd_ha_data(const void* thd, const struct handlerton *hton);
186
void thd_storage_lock_wait(void* thd, long long value);
187
int thd_tx_isolation(const void* thd);
188
char *thd_security_context(void* thd, char *buffer, unsigned int length,
189
unsigned int max_query_len);
190
void thd_inc_row_count(void* thd);
191
int mysql_tmpfile(const char *prefix);
192
unsigned long thd_get_thread_id(const void* thd);
193
void thd_get_xid(const void* thd, MYSQL_XID *xid);
194
void mysql_query_cache_invalidate4(void* thd,
195
const char *key, unsigned int key_length,
197
void *thd_get_ha_data(const void* thd, const struct handlerton *hton);
198
void thd_set_ha_data(void* thd, const struct handlerton *hton,
199
const void *ha_data);
200
enum enum_ftparser_mode
202
MYSQL_FTPARSER_SIMPLE_MODE= 0,
203
MYSQL_FTPARSER_WITH_STOPWORDS= 1,
204
MYSQL_FTPARSER_FULL_BOOLEAN_INFO= 2
206
enum enum_ft_token_type
210
FT_TOKEN_LEFT_PAREN= 2,
211
FT_TOKEN_RIGHT_PAREN= 3,
214
typedef struct st_mysql_ftparser_boolean_info
216
enum enum_ft_token_type type;
223
} MYSQL_FTPARSER_BOOLEAN_INFO;
224
typedef struct st_mysql_ftparser_param
226
int (*mysql_parse)(struct st_mysql_ftparser_param *,
227
const char *doc, int doc_len);
228
int (*mysql_add_word)(struct st_mysql_ftparser_param *,
229
const char *word, int word_len,
230
MYSQL_FTPARSER_BOOLEAN_INFO *boolean_info);
231
void *ftparser_state;
233
const struct charset_info_st *cs;
237
enum enum_ftparser_mode mode;
238
} MYSQL_FTPARSER_PARAM;
239
struct st_mysql_ftparser
241
int interface_version;
242
int (*parse)(MYSQL_FTPARSER_PARAM *param);
243
int (*init)(MYSQL_FTPARSER_PARAM *param);
244
int (*deinit)(MYSQL_FTPARSER_PARAM *param);