NAME
Kwiki::DB::DBI - A DBI.pm wrapper as a Kwiki base class.
SYNOPSIS
package Kwiki::MyPlugin;
use Kwiki::Plugin -Base;
const db_class => 'Kwiki::DB::DBI';
sub action {
$self->db->connect($dsn,$user,$password);
$self->db->do(...);
$self->db->$dbi_method(...);
}
DESCRIPTION
This class is for those pure DBI.pm lover. It does nothing but let DBI.pm do all the work. Plugin writers who want to use this module, just put a line:
const db_class => 'Kwiki::DB::DBI';
in there plugin module, and there will be a convienent $hub-
db> reference to an instantiated DBI object. After that, just follow the manual of DBI.pm to use the DBI object.
SEE ALSO
COPYRIGHT
Copyright 2005 by Kang-min Liu <gugod@gugod.org>.
This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
See <http://www.perl.com/perl/misc/Artistic.html>