On Sat, 18 Dec 2004 19:08:03 -0800, Joe Rinehart <[EMAIL PROTECTED]> wrote: > I've been down the 'universal base' road and kicked myself for it > later, but I can't really articulate why as, in my head, it's still > specific to the situation I was in. What would be some of the reasons > you'd avoid it, Sean?
Mostly because inheritance introduces a very tight coupling between the base class and all derived classes - and inheritance should be a pure "is-a" relationship. Those combined mean that a universal base class both limits your options (to model real "is-a" relationships between objects) and introduces an artificial "sibling" relationship between objects that extend the universal base class. It's hard to quantity the amount of problems it causes because, well, in a particular application it might not cause any problems. At least, not at first. But it generally smacks of reuse-via-inheritance which is just not a good idea. I blogged a little bit about this some time ago: http://www.corfield.org/blog/index.cfm?do=blog.entry&entry=E081459B-FC2D-0B11-ECBB5B4A2B494361 Whilst Holub might be controversial in many ways, his rants have a solid seed of truth behind them... -- Sean A Corfield -- http://www.corfield.org/ Team Fusebox -- http://www.fusebox.org/ Breeze Me! -- http://www.corfield.org/breezeme "If you're not annoying somebody, you're not really alive." -- Margaret Atwood ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Special thanks to the CF Community Suite Gold Sponsor - CFHosting.net http://www.cfhosting.net Message: http://www.houseoffusion.com/lists.cfm/link=i:4:188185 Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4 Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4 Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4 Donations & Support: http://www.houseoffusion.com/tiny.cfm/54

