~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to drizzled/plugin/plugin.h

  • Committer: Brian Aker
  • Date: 2010-10-26 21:34:15 UTC
  • mto: (1887.2.1 merge)
  • mto: This revision was merged to the branch mainline in revision 1888.
  • Revision ID: brian@tangent.org-20101026213415-666ezkzx542h8uf0
Adding cache.h for definition.

Show diffs side-by-side

added added

removed removed

Lines of Context:
25
25
 
26
26
namespace drizzled
27
27
{
 
28
namespace module
 
29
{
 
30
class Module;
 
31
}
 
32
 
28
33
namespace plugin
29
34
{
30
35
 
31
 
class Module;
32
 
 
33
36
class Plugin
34
37
{
35
38
private:
36
39
  const std::string name;
37
40
  bool is_active;
38
 
  Module *module;
 
41
  module::Module *module;
39
42
  const std::string type_name;
40
43
 
41
44
  Plugin();
46
49
  explicit Plugin(std::string in_name, std::string in_type_name);
47
50
  virtual ~Plugin() {}
48
51
 
 
52
  /*
 
53
   * This method is called for all plug-ins on shutdown,
 
54
   * _before_ the plug-ins are deleted. It can be used
 
55
   * when shutdown code references other plug-ins.
 
56
   */
 
57
  virtual void shutdownPlugin()
 
58
  {
 
59
  }
 
60
 
49
61
  void activate()
50
62
  {
51
63
    is_active= true;
66
78
    return name;
67
79
  } 
68
80
 
69
 
  void setModule(Module *module_arg)
 
81
  void setModule(module::Module *module_arg)
70
82
  {
71
83
    module= module_arg;
72
84
  }