Eliminating repetition and encouraging code reuse are central tenets of software development.
PHP’s lack of multiple inheritance means sometimes there are tough design choices to be made when similar functionality is required in separate branches of the class heirarchy.
As proposed in the Horizontal Reuse for PHP RFC, traits offer a means of duplicating functionality in [...]
Tag Archives: reflection
Trait-like Functionality for PHP
by Steve on 05. Apr, 2010 in PHP
About Steve
PHP developer, internet marketeer and owner of Dogfood Media. A Zend Certified Engineer, loves his two dogs and home brewing. Lives by the sea in Kent.
Recent Comments