tags:

views:

58

answers:

2

Let's say I have an abstract class called ViewController, and another abstract class called FormViewController. When someone wants to create a form, he must subclass FormViewController and implement its abstract classes.

ViewController defines an abstract method loadView() and viewDidLoad(). FormViewController implements loadView() but does not implement viewDidLoad(). So the user must implement that.

Is this okay with PHP's OOP?

+4  A: 

It's okay with any object-oriented language. The best way to prove it is to try it and see.

duffymo
+2  A: 

yes, actually thats a widelly used design pattern on many OOP languages.

sap