Re: MDB 2.0 question
| From: | Bertrand Mansion | Date: | Sat, 19 Jul 2003 08:33:51 +0000 |
| Subject: | Re: MDB 2.0 question | ||
| References: | 1 | Groups: | php.pear.dev |
| Request: | Send a blank email to pear-dev+get-18413@lists.php.net to get a copy of this message | ||
<smith@backendmedia.com> wrote :
>> From: Lukas Smith [mailto:smith@backendmedia.com]
>> Sent: Friday, July 18, 2003 6:39 PM
>
>> ok I have a little question about MDB 2.0 and I am interested in your
>> opinions. Basically I want to move some functionality into separate
>> classes that will be loaded as class properties.
>>
>> Actually this is already done in the management methods in MDB 1.x.
>> However I am not sure if I really like how its done there.
>>
>> Let me explain:
>
> <snip attempt to explain>
>
> Maybe I need to make this even simplier.
> In the current way people would need to call createDatabase() as
> follows:
> $mdb->manager->createDatabase($mdb, $name);
>
> In the new way it would be:
> $mdb->manager->createDatabase($name);
That's a design problem and really it should be up to you because both
solutions have pros and cons. It's not by asking people for what they think
that you will find the best way. Personally, I would prefer solution 1 that
makes it possible to call the method statically. But you seem to prefer
solution 2 because it's easier to use... So you see, no real good solution,
it's up to what you want to allow with MDB 2.0.
Bertrand Mansion
Mamasam