summaryrefslogtreecommitdiff
path: root/ext/mysqlnd/mysqlnd_structs.h
diff options
context:
space:
mode:
authorAndrey Hristov <andrey@php.net>2010-12-28 15:16:21 +0000
committerAndrey Hristov <andrey@php.net>2010-12-28 15:16:21 +0000
commitcfac5f5b674a038a35043018145bc61584695fdb (patch)
tree88d0db8340a1ccc42800ee93da48732d5df73c6b /ext/mysqlnd/mysqlnd_structs.h
parent874954ed97e0328adf57470230f7f16552ba225c (diff)
downloadphp-git-cfac5f5b674a038a35043018145bc61584695fdb.tar.gz
extending the API interface - plugins can register
themselves with a structure and can be searched. Every plugin can have statistics and they are shown under the statistics of mysqlnd in MINFO.
Diffstat (limited to 'ext/mysqlnd/mysqlnd_structs.h')
-rw-r--r--ext/mysqlnd/mysqlnd_structs.h42
1 files changed, 42 insertions, 0 deletions
diff --git a/ext/mysqlnd/mysqlnd_structs.h b/ext/mysqlnd/mysqlnd_structs.h
index a04fc49e3c..ff3470b281 100644
--- a/ext/mysqlnd/mysqlnd_structs.h
+++ b/ext/mysqlnd/mysqlnd_structs.h
@@ -921,4 +921,46 @@ struct st_mysqlnd_stmt
zend_bool persistent;
};
+
+typedef struct st_mysqlnd_string
+{
+ char *s;
+ size_t l;
+} MYSQLND_STRING;
+
+
+struct st_mysqlnd_plugin_header
+{
+ unsigned int plugin_api_version;
+ const char * plugin_name;
+ unsigned long plugin_version;
+ const char * plugin_string_version;
+ const char * plugin_license;
+ const char * plugin_author;
+ struct
+ {
+ MYSQLND_STATS * values;
+ const MYSQLND_STRING * names;
+ } plugin_stats;
+
+ struct
+ {
+ enum_func_status (*plugin_shutdown)(void * plugin TSRMLS_DC);
+ } m;
+};
+
+
+struct st_mysqlnd_plugin_core
+{
+ struct st_mysqlnd_plugin_header plugin_header;
+};
+
+
+struct st_mysqlnd_typeii_plugin_example
+{
+ struct st_mysqlnd_plugin_header plugin_header;
+ void * methods;
+ unsigned int counter;
+};
+
#endif /* MYSQLND_STRUCTS_H */