News Feed
Sections




News Archive
Looking for more information on how to do PHP the right way? Check out PHP: The Right Way

Nefarious Designs:
Object-Oriented PHP Part 3 Taking Relationships Further
August 23, 2006 @ 06:33:31

Nefarious Designs has posted the next part of their "Object-Oriented PHP" series today, the third part looking at how to take the relationships (discussed in part two) even further.

In "Part 1: Definition" we took a look at defining objects and classes in PHP. In "Part 2: Relationships" we looked at linking our objects and classes together. In part 3 I'm going to add to those relationships by looking at visibility, polymorphism and the scope resolution operator.

He starts off with a look at access modifiers (private, public, protected) on both attributes and methods. Next is a look at polymorphism with an example of using a getHTML function in both a base formElement class and the child class of textarea. He then talks about the scope resolution operator (::) and its use in parent/child relationships and in PHP5's scope.

0 comments voice your opinion now!
part3 object oriented relationships further access polymorphism part3 object oriented relationships further access polymorphism


blog comments powered by Disqus

Similar Posts

Chris Hartjes' Blog: Metatesting: Understanding Mock Objects

Jeff Moore's Blog: Let Your Properties be Properties

Dagfinn Reiersol's Blog: Real programming with PHP 5.3 (part 3): Links

PHPClasses.org: The Secret PHP Optimization of version 5.4

Project: Aleksey Martynov's lexa-xml-serialization Tool for PHP 5.3


Community Events





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


code framework project developer series introduction configure api wordpress interview threedevsandamaybe library podcast list application community release language laravel bugfix

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