~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to plugin/database_function/database_function.cc

  • Committer: Eric Day
  • Date: 2010-03-25 19:28:37 UTC
  • mfrom: (1405 staging)
  • mto: This revision was merged to the branch mainline in revision 1409.
  • Revision ID: eday@oddments.org-20100325192837-4exmacbrywjovsqp
Merged trunk, rsolved conflicts.

Show diffs side-by-side

added added

removed removed

Lines of Context:
55
55
 
56
56
plugin::Create_function<DatabaseFunction> *database_function= NULL;
57
57
 
58
 
static int initialize(drizzled::plugin::Registry &registry)
 
58
static int initialize(drizzled::plugin::Context &context)
59
59
{
60
60
  database_function= new plugin::Create_function<DatabaseFunction>("database");
61
 
  registry.add(database_function);
 
61
  context.add(database_function);
62
62
  return 0;
63
63
}
64
64
 
65
 
static int finalize(drizzled::plugin::Registry &registry)
66
 
{
67
 
   registry.remove(database_function);
68
 
   delete database_function;
69
 
   return 0;
70
 
}
71
 
 
72
65
DRIZZLE_DECLARE_PLUGIN
73
66
{
74
67
  DRIZZLE_VERSION_ID,
78
71
  "returns the current database",
79
72
  PLUGIN_LICENSE_GPL,
80
73
  initialize, /* Plugin Init */
81
 
  finalize,   /* Plugin Deinit */
82
74
  NULL,   /* system variables */
83
75
  NULL    /* config options */
84
76
}