00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022 #pragma once
00023
00024 #include <drizzled/plugin/plugin.h>
00025
00026 #include <string>
00027
00028 #include <drizzled/visibility.h>
00029
00030 namespace drizzled
00031 {
00032 class Session;
00033
00034 namespace plugin
00035 {
00036
00037 class DRIZZLED_API Logging : public Plugin
00038 {
00039 Logging();
00040 Logging(const Logging &);
00041 Logging& operator=(const Logging &);
00042 public:
00043 explicit Logging(std::string name_arg)
00044 : Plugin(name_arg, "Logging")
00045 {}
00046 virtual ~Logging() {}
00047
00052 virtual bool pre(Session *) {return false;}
00053 virtual bool post(Session *) {return false;}
00054 virtual bool postEnd(Session*) {return false;}
00055 virtual bool resetGlobalScoreboard() {return false;}
00056
00057 static bool addPlugin(Logging *handler);
00058 static void removePlugin(Logging *handler);
00059 static bool preDo(Session *session);
00060 static bool postDo(Session *session);
00061 static bool postEndDo(Session *session);
00062 static bool resetStats(Session *session);
00063 };
00064
00065 }
00066 }
00067