[Maypole] Using Maypole with existing Class::DBI classes

Simon Cozens simon@simon-cozens.org
Wed, 2 Jun 2004 09:44:26 +0100


Marcus Ramberg:
> >I am very impressed by Maypole and want to use it with a set of classes
> >I've written using Class::DBI before I stubled on this framework. I
> >could not use Maypole::Model::CDBI because the classes have names that
> >are slightly different from those produced by Class::DBI::Loader.
>
> Hi Sebastian. Maypole::Model::CDBI does not require  Class::DBI::Loader. 

Yes, it does.

> You can write normal CDBI classes and inherit from Maypole::Model::CDBI 
> , see the Flox example in http://cvs.simon-cozens.org/viewcvs.cgi/flox/ 
> for an example of an application that does this.
 
This doesn't solve the problem of the CDBI::Loader class names being different
from the ones you choose yourself. I'm about to need to write
Maypole::Model::CDBI::Plain, which overrides the setup_database and class_of
methods to take a DSN, username, password and list of classes. It's
sufficiently trivial that I could do it today, but I want to wait until
Email::Store is done (by the end of this week) so I can get it heavily tested.

-- 
Oh dear. I've just realised that my fvwm config lasted longer than my
marriage, in that case.
    - Anonymous