Statistics for MySQL  1.1
 All Classes Files Functions Variables Typedefs Macros Pages
sqlplugin.h
Go to the documentation of this file.
1 /* sqlplugin.h (plugin) */
2 
3 /***********************************************************************
4 * This code is part of Statistics for MySQL.
5 *
6 * Copyright (C) 2011 Heinrich Schuchardt (xypron.glpk@gmx.de)
7 *
8 * Licensed under the Apache License, Version 2.0 (the "License");
9 * you may not use this file except in compliance with the License.
10 * You may obtain a copy of the License at
11 *
12 * http://www.apache.org/licenses/LICENSE-2.0
13 *
14 * Unless required by applicable law or agreed to in writing, software
15 * distributed under the License is distributed on an "AS IS" BASIS,
16 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
17 * See the License for the specific language governing permissions and
18 * limitations under the License.
19 ***********************************************************************/
20 
28 #ifndef SQLPLUGIN
29 #define SQLPLUGIN
30 
31 #if defined HAVE_CONFIG_H
32 #include "config.h"
33 #endif // HAVE_CONFIG_H
34 
35 #ifdef __cplusplus
36 extern "C"
37 {
38 #endif
39 
44  int interface_version;
45 } plugin_info =
46 { 0 };
47 
52 
53 MYSQL_SYSVAR_STR(version, version_value, PLUGIN_VAR_READONLY,
54  "Statistics for MySQL release", NULL, NULL, VERSION);
55 
59 struct st_mysql_sys_var* plugin_sys_var[] = {
60  MYSQL_SYSVAR(version),
61  NULL
62 };
63 
64 mysql_declare_plugin(sqlstat_plugin)
65 {
66  MYSQL_UDF_PLUGIN,
67  &plugin_info,
68  "libsqlstat",
69  "Heinrich Schuchardt (xypron.glpk@gmx.de)",
70  "Statistics for MySQL (http://sqlstat.sourceforge.net)",
71  PLUGIN_LICENSE_PROPRIETARY,
74  0x0010, // 0.10
75  NULL,
77  NULL
78 }
79 mysql_declare_plugin_end;
80 
81 #ifdef __cplusplus
82 }
83 #endif
84 
85 #endif // SQLPLUGIN
int sqlstat_plugin_deinit(void *p)
Deinitializes plugin.
Definition: sqlplugin.cc:57
struct st_mysql_sys_var * plugin_sys_var[]
System variables definition.
Definition: sqlplugin.h:59
Udf plugin information.
Definition: sqlplugin.h:43
int sqlstat_plugin_init(void *p)
Initializes plugin.
Definition: sqlplugin.cc:44
char * version_value
Plugin version.
Definition: sqlplugin.h:51