[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: OO should break when broken(was re: the benefits of immutability)



On Monday, September 1, 2003, at 11:50 AM, James McCartney wrote:
> If you are in this situation it means that you probably should have 
> had an abstract class which is a common ancestor of these two classes.

I pulled the Circle/Ellipse radius/{x-radius,y-radius} out of the 
discussion just as an example.  What actually happened was, I trying to 
extend OpenMap classes, in and of themselves very useful, and finding 
that I wished a few things had been put elsewhere rather in than the 
classes I was extending.  I think the authors' design was fine.  I made 
an extension that might not have been anticipated.  Redesign involves 
dialog with the original authors, but when time is short, I wish there 
were easier and more immediate ways of reshaping classes.

Geoffrey
--
Geoffrey S. Knauth | http://knauth.org/gsk