5
votes
Vote UpVote

Hiding the TObject.Create constructor

Andy's Blog – If you design your classes you may get to a point where you want to have multiple overloaded constructors in your class. But all these overloaded constructors have parameters and a parameter-less constructor doesn’t make sense. And it should be forbidden to call it. Unfortunately Delphi doesn’t allow you to hide the inherited TObject.Create constructor and you end up with a class where you implement the parameter-less constructor just to throw an exception. But why should you implement something that you obviously do not want anybody to call. Well, you do not need to. You can hide the ...
Favorite? Off-Topic? Andreas Hausladen @ 2011-07-28 21:02

Statistics

Visits: 1146
Votes: 5
Favorites: 0
Off-Topic: 0

Visits by Source

User Actions

Users who voted for this posting

Alister Christie
Chiral
Ravaut123
TDelphiHobbyist
vcldeveloper
Subscribe:
Contact us to advertise on DelphiFeeds.com

Community Links

Torry Firebird News

Sponsor

 
Please login or register to use this functionality.
(click on this box to dismiss)