Re: PHP object communication

From: Date: Wed, 24 Oct 2001 22:50:10 +0000
Subject: Re: PHP object communication
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-72180@lists.php.net to get a copy of this message
On Mié 24 Oct 2001 19:45, ad@m.beecher.net wrote: > > I think you have things mistaken. What you want is to EXTEND an existing > > object with new variables and functions. See class CLASS_NAME EXTENDS > > OLD_CLASS. > > Quick answer appreciated Martín, but I really don't. I'd like to keep, for > example, the $Core->Error and $Core->DB objects separate from each other, > while still allowing them to talk to each other. I've been playing with > this for ages, and I'm starting to feel that I've seriously overcomplicated > it for myself. I mean, it's just inter-object communication, isn't it? :) <checking OOP books> I think that's not how Objects work in a real OOP aplication, and I think yu should think about using EXTENDS. </checking OOP books> You can create new classes that extend the same OLD_CLASS, so I can't imaging why you don't want to extend it? P.D.: Maybe you need something even more powerfull, that PHP doesn't have at this moment. Multiple extends (create a new class that extends more then one class). Saludos... :-) -- Porqué usar una base de datos relacional cualquiera, si podés usar PostgreSQL? ----------------------------------------------------------------- Martín Marqués | mmarques@unl.edu.ar Programador, Administrador, DBA | Centro de Telematica Universidad Nacional del Litoral -----------------------------------------------------------------

« previous php.general (#72180) next »