Page 1 of 1
Extend or custom class
Posted: Wed Jan 24, 2007 10:36 am
by user___
Hi guys,
I wonder whether it is better to create your application with extend or with a custom class(which does the same as extend.
Posted: Wed Jan 24, 2007 10:38 am
by Luke
umm I'm not sure I understand your question... an application is usually composed of more than one class.
Posted: Wed Jan 24, 2007 12:27 pm
by Christopher
There are times when extending a base class is the best choice; other times when creating a new class is the best choice; a third path is composition where you pass an object to another object that uses it to add to its functionality without inheritance. One is not better than another.