Re: Confusion With Inheritance
- From: Robert C. Martin <unclebob@xxxxxxxxxxxxxxxx>
- Date: Sat, 27 Aug 2005 12:03:21 -0500
On 25 Aug 2005 19:45:31 -0700, "Brad" <bradwebber@xxxxxxxxx> wrote:
>Let's say the Product class does survive as a class. Am I correct in
>assuming that you would discourage subclassing SkinCare products and
>Makeup products and instead design a single Product class that had
>UNDEFINED attributes depending on the type of product that was
>instantiated?
No, not at all. The point is that I don't know what the partitioning
of the system ought to be because I don't know what the system does.
Until I know the behavior of the system, speculating on an object
model is fruitless.
-----
Robert C. Martin (Uncle Bob) | email: unclebob@xxxxxxxxxxxxxxxx
Object Mentor Inc. | blog: www.butunclebob.com
The Agile Transition Experts | web: www.objectmentor.com
800-338-6716
"The aim of science is not to open the door to infinite wisdom,
but to set a limit to infinite error."
-- Bertolt Brecht, Life of Galileo
.
- References:
- Confusion With Inheritance
- From: Brad
- Re: Confusion With Inheritance
- From: Robert C . Martin
- Re: Confusion With Inheritance
- From: Brad
- Confusion With Inheritance
- Prev by Date: Re: Confusion With Inheritance
- Next by Date: Re: chooses not to generate code at all
- Previous by thread: Re: Confusion With Inheritance
- Next by thread: precondition and postcondition
- Index(es):