News Feed
Jobs Feed
Sections

Recent Jobs

News Archive
Christian Stocker's Blog:
FOTD REFLECTIONCLASS()->NEWINSTANCEARGS($ARGS) is "slow"
September 18, 2008 @ 13:17:36

Christan Stocker has posted a finding of the day that he ran across and wanted to share to help out other developers out there:

For okapi we needed to have a function which loads any class with any number of arguments. This is not so easy in PHP as it looks like [...] Since 5.1.3 you can use the reflection extension to do this much nicer.

The difference comes in at about half the time for both side of the examples - with the switch and via reflection.

0 comments voice your opinion now!
reflection switch instance class arguments



Similar Posts

Mike Wallner's Blog: HttpRequestDataShare

DevShed: PHP 5 and Polymorphism

Cesarodas.com: gCache: Helping PHP to work faster

Cesarodas.com: gCache: Helping PHP to work faster

Arnold Daniels' Blog: A dark corner of PHP: class casting


Community Events







Don't see your event here?
Let us know!


releases mysql application zendframework zend job framework ajax book example code cakephp developer security database release conference PHP5 PEAR package

All content copyright, 2008 PHPDeveloper.org :: info@phpdeveloper.org - Powered by the Solar PHP Framework