[fpc-devel] class abstract, class sealed implementation. please review.

Graeme Geldenhuys graemeg.lists at gmail.com
Fri Oct 16 23:01:42 CEST 2009


2009/10/16 Paul Ishenin <webpirat at mail.ru>:
> Sealed class is a class which can't be derived by another class. This one is
> fully supported by delphi.

Would you mind explaining this - I never saw the benefit of a sealed
class. Using myself as an example. Say I develop some kick-ass OOP
framework. There is no way in hell I can forsee every possible use of
the classes I created. So why would I want to limit the usefulness of
a class - it goes totally against the OOP principles.

Imagine the TList class was a sealed classes. We would never have been
able to create a TObjectList, TInterfaceList, TStringList, etc... and
reusing the basic implementation from TList to save time and code
reuse.

Not to shoot down your efforts or anything, I just don't understand
the point of a sealed class. It sounds more like something Microsoft
would implement to stop developers from reusing their classes like
"Outlook Bar" and extend it to something much better than the standard
one included in MS Office.

-- 
Regards,
  - Graeme -


_______________________________________________
fpGUI - a cross-platform Free Pascal GUI toolkit
http://opensoft.homeip.net/fpgui/



More information about the fpc-devel mailing list