~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to plugin/single_thread/single_thread.cc

  • Committer: Tim Penhey
  • Date: 2010-01-20 02:39:01 UTC
  • mto: This revision was merged to the branch mainline in revision 1275.
  • Revision ID: tim.penhey@canonical.com-20100120023901-8teeunid6gwlthzx
Add in a rot 13 function.

Show diffs side-by-side

added added

removed removed

Lines of Context:
24
24
static SingleThreadScheduler *scheduler= NULL;
25
25
 
26
26
 
27
 
static int init(plugin::Context &context)
 
27
static int init(drizzled::plugin::Registry &registry)
28
28
{
29
29
  scheduler= new SingleThreadScheduler("single_thread");
30
 
  context.add(scheduler);
31
 
  return 0;
32
 
}
 
30
  registry.add(scheduler);
 
31
  return 0;
 
32
}
 
33
 
 
34
static int deinit(drizzled::plugin::Registry &registry)
 
35
{
 
36
  registry.remove(scheduler);
 
37
  delete scheduler;
 
38
 
 
39
  return 0;
 
40
}
 
41
 
 
42
static drizzle_sys_var* system_variables[]= {
 
43
  NULL
 
44
};
33
45
 
34
46
DRIZZLE_DECLARE_PLUGIN
35
47
{
40
52
  "Single Thread Scheduler",
41
53
  PLUGIN_LICENSE_GPL,
42
54
  init, /* Plugin Init */
43
 
  NULL,   /* system variables */
 
55
  deinit, /* Plugin Deinit */
 
56
  NULL,   /* status variables */
 
57
  system_variables,   /* system variables */
44
58
  NULL    /* config options */
45
59
}
46
60
DRIZZLE_DECLARE_PLUGIN_END;