I totally agree with you!!

>From what someone told me, the new version of the Zend engine will fully
support OOP (but don't quote me on this as I haven't had time to look at the
Zend site to confirm this) - I'm looking forward to seeing it. This would
make PHP a really powerful language then!!

Martin


-----Original Message-----
From: Colin Tucker [mailto:[EMAIL PROTECTED]]
Sent: Monday, December 17, 2001 11:42 AM
To: [EMAIL PROTECTED]
Subject: [PHP] PHP object-oriented features


Hi there,

Just wondering if there is any plans for more work on the PHP OO features,
and/or the parser in relation to these features.  Generally I find the PHP
OO features to be quite useful, but there is some major limitations which
often frustrate me at times, for example:

$result = $object->method()->returnedObject->anotherMethod();

That won't work with PHP as it is now.  Instead, you'd have to do this:

$returnedObject = $object->method();

$result = $returnedObject->anotherMethod();

:(

Seems like a simple annoyance, right?  Well some code I'm working on would
work best like this:

$object->getSomething()->getSomething()->getSomething()->addSomething("foo")
;

Instead, all you can do is this:

$result = $object->getSomething();

$result = $result->getSomething();

$result = $result->getSomething();

$result->addSomething("foo");

Again, not good.  :(

Another thing is multiple inheritance, or 'implementing' an object, rather
than extending just one.  Like this:

class Foo extends Bar implements Eep
{

}

Foo is a subclass of Bar, but *uses* the methods/attributes of Eep.

Yeah, I know, PHP is not at heart an OO language, but I really LIKE PHP!  I
don't want to use JSP or something because I think Java is slow and over
complicated.  So, is there any chance that these features could be added in
the future at some stage?  Please?  ;)

Cheers,

Colin.



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to