~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to drizzled/plugin/error_message.h

  • Committer: Brian Aker
  • Date: 2011-02-01 20:31:20 UTC
  • mfrom: (2133.1.4 drizzle-build)
  • Revision ID: brian@tangent.org-20110201203120-vmp2abdbjjaua218
Merge in all of the error cleanup.

Show diffs side-by-side

added added

removed removed

Lines of Context:
23
23
#define DRIZZLED_PLUGIN_ERROR_MESSAGE_H
24
24
 
25
25
#include "drizzled/plugin/plugin.h"
 
26
#include "drizzled/error/level_t.h"
26
27
 
27
28
#include <stdarg.h>
28
29
 
32
33
 
33
34
namespace drizzled
34
35
{
35
 
class Session;
36
36
 
37
37
namespace plugin
38
38
{
42
42
  ErrorMessage();
43
43
  ErrorMessage(const ErrorMessage &);
44
44
  ErrorMessage& operator=(const ErrorMessage &);
 
45
 
45
46
public:
46
47
  explicit ErrorMessage(std::string name_arg)
47
48
   : Plugin(name_arg, "ErrorMessage")
48
49
  {}
49
50
  virtual ~ErrorMessage() {}
50
51
 
51
 
  virtual bool errmsg(Session *session, int priority,
52
 
                      const char *format, va_list ap)=0;
 
52
  virtual bool errmsg(error::level_t priority, const char *format, va_list ap)=0;
53
53
 
54
54
  static bool addPlugin(plugin::ErrorMessage *handler);
55
55
  static void removePlugin(plugin::ErrorMessage *handler);
56
56
 
57
 
  static bool vprintf(Session *session, int priority, char const *format,
58
 
                      va_list ap);
 
57
  static bool vprintf(error::level_t priority, char const *format, va_list ap);
59
58
};
60
59
 
61
60
} /* namespace plugin */