Re: [PHP] Q on Class, inhertance, ec... (a bit long)

2003-09-25 Thread Robert Cummings
class FOO { function Fred() { echo "Fred in FOO"; } } class BAR { function Fred() { echo "Fred in BAR"; } } class BAZFactory {

Re: [PHP] Q on Class, inhertance, ec... (a bit long)

2003-09-25 Thread jsWalter
"Martin Towell" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > What about something like this? I've been playing with that same approach this evening. But I guess I was hoping for a more direct, 1 level of inderection instead of 2. But, by making a "base" method in the main cl

RE: [PHP] Q on Class, inhertance, ec... (a bit long)

2003-09-25 Thread Martin Towell
->subclass = new FOO(); if ($num == 2) $this->subclass = new BAR(); } function Fred() { $this->subclass->Fred(); } } -Original Message- From: jsWalter [mailto:[EMAIL PROTECTED] Sent: Thursday, 25 September 2003 4:30 PM To: [EMAIL PROTECTED] Subject: [PHP] Q on Class, in

[PHP] Q on Class, inhertance, ec... (a bit long)

2003-09-24 Thread jsWalter
I have a quandary and I hope I can explain myself well enough that someone may understand and enlighten me. I am in the middle of building a (largish) Class. It is done for the most part, at least all pieces are there. Now I'm just trying to put the pieces together in a logical order. This is my i