~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to drizzled/plugin/registry.cc

  • Committer: Monty Taylor
  • Date: 2009-08-05 09:29:04 UTC
  • mto: (1093.1.57 captain)
  • mto: This revision was merged to the branch mainline in revision 1115.
  • Revision ID: mordred@inaugust.com-20090805092904-a26m53g5b345dtql
Renamed PluginRegistry to plugin::Registry.

Show diffs side-by-side

added added

removed removed

Lines of Context:
18
18
 */
19
19
 
20
20
#include "drizzled/server_includes.h"
21
 
#include "drizzled/plugin_registry.h"
 
21
#include "drizzled/plugin/registry.h"
22
22
 
23
23
#include "drizzled/plugin.h"
24
24
#include "drizzled/show.h"
39
39
using namespace std;
40
40
using namespace drizzled;
41
41
 
42
 
static PluginRegistry the_registry;
43
 
 
44
 
PluginRegistry& PluginRegistry::getPluginRegistry()
45
 
{
46
 
  return the_registry;
47
 
}
48
 
 
49
 
plugin::Handle *PluginRegistry::find(const LEX_STRING *name)
 
42
 
 
43
plugin::Handle *plugin::Registry::find(const LEX_STRING *name)
50
44
{
51
45
  string find_str(name->str,name->length);
52
46
  transform(find_str.begin(), find_str.end(), find_str.begin(), ::tolower);
58
52
  return(0);
59
53
}
60
54
 
61
 
void PluginRegistry::add(plugin::Handle *plugin)
 
55
void plugin::Registry::add(plugin::Handle *plugin)
62
56
{
63
57
  string add_str(plugin->getName());
64
58
  transform(add_str.begin(), add_str.end(),
68
62
}
69
63
 
70
64
 
71
 
vector<plugin::Handle *> PluginRegistry::get_list(bool active)
 
65
vector<plugin::Handle *> plugin::Registry::get_list(bool active)
72
66
{
73
67
  plugin::Handle *plugin= NULL;
74
68
 
90
84
  return plugins;
91
85
}
92
86
 
93
 
void PluginRegistry::add(StorageEngine *engine)
 
87
void plugin::Registry::add(StorageEngine *engine)
94
88
{
95
89
  add_storage_engine(engine);
96
90
}
97
91
 
98
 
void PluginRegistry::add(InfoSchemaTable *schema_table)
 
92
void plugin::Registry::add(InfoSchemaTable *schema_table)
99
93
{
100
94
  add_infoschema_table(schema_table);
101
95
}
102
96
 
103
 
void PluginRegistry::add(Function_builder *udf)
 
97
void plugin::Registry::add(Function_builder *udf)
104
98
{
105
99
  add_udf(udf);
106
100
}
107
101
 
108
 
void PluginRegistry::add(Logging_handler *handler)
 
102
void plugin::Registry::add(Logging_handler *handler)
109
103
{
110
104
  add_logger(handler);
111
105
}
112
106
 
113
 
void PluginRegistry::add(Error_message_handler *handler)
 
107
void plugin::Registry::add(Error_message_handler *handler)
114
108
{
115
109
  add_errmsg_handler(handler);
116
110
}
117
111
 
118
 
void PluginRegistry::add(Authentication *auth)
 
112
void plugin::Registry::add(Authentication *auth)
119
113
{
120
114
  add_authentication(auth);
121
115
}
122
116
 
123
 
void PluginRegistry::add(QueryCache *qcache)
 
117
void plugin::Registry::add(QueryCache *qcache)
124
118
{
125
119
  add_query_cache(qcache);
126
120
}
127
121
 
128
 
void PluginRegistry::add(plugin::SchedulerFactory *factory)
 
122
void plugin::Registry::add(plugin::SchedulerFactory *factory)
129
123
{
130
124
  add_scheduler_factory(factory);
131
125
}
132
126
 
133
127
 
134
 
void PluginRegistry::add(plugin::Replicator *replicator)
 
128
void plugin::Registry::add(plugin::Replicator *replicator)
135
129
{
136
130
  add_replicator(replicator);
137
131
}
138
132
 
139
 
void PluginRegistry::add(plugin::Applier *applier)
 
133
void plugin::Registry::add(plugin::Applier *applier)
140
134
{
141
135
  add_applier(applier);
142
136
}
143
137
 
144
 
void PluginRegistry::remove(StorageEngine *engine)
 
138
void plugin::Registry::remove(StorageEngine *engine)
145
139
{
146
140
  remove_storage_engine(engine);
147
141
}
148
142
 
149
 
void PluginRegistry::remove(InfoSchemaTable *schema_table)
 
143
void plugin::Registry::remove(InfoSchemaTable *schema_table)
150
144
{
151
145
  remove_infoschema_table(schema_table);
152
146
}
153
147
 
154
 
void PluginRegistry::remove(Function_builder *udf)
 
148
void plugin::Registry::remove(Function_builder *udf)
155
149
{
156
150
  remove_udf(udf);
157
151
}
158
152
 
159
 
void PluginRegistry::remove(Logging_handler *handler)
 
153
void plugin::Registry::remove(Logging_handler *handler)
160
154
{
161
155
  remove_logger(handler);
162
156
}
163
157
 
164
 
void PluginRegistry::remove(Error_message_handler *handler)
 
158
void plugin::Registry::remove(Error_message_handler *handler)
165
159
{
166
160
  remove_errmsg_handler(handler);
167
161
}
168
162
 
169
 
void PluginRegistry::remove(Authentication *auth)
 
163
void plugin::Registry::remove(Authentication *auth)
170
164
{
171
165
  remove_authentication(auth);
172
166
}
173
167
 
174
 
void PluginRegistry::remove(QueryCache *qcache)
 
168
void plugin::Registry::remove(QueryCache *qcache)
175
169
{
176
170
  remove_query_cache(qcache);
177
171
}
178
172
 
179
 
void PluginRegistry::remove(plugin::SchedulerFactory *factory)
 
173
void plugin::Registry::remove(plugin::SchedulerFactory *factory)
180
174
{
181
175
  remove_scheduler_factory(factory);
182
176
}
183
177
 
184
178
 
185
 
void PluginRegistry::remove(plugin::Replicator *replicator)
 
179
void plugin::Registry::remove(plugin::Replicator *replicator)
186
180
{
187
181
  remove_replicator(replicator);
188
182
}
189
183
 
190
 
void PluginRegistry::remove(plugin::Applier *applier)
 
184
void plugin::Registry::remove(plugin::Applier *applier)
191
185
{
192
186
  remove_applier(applier);
193
187
}