From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.3 required=5.0 tests=BAYES_00,INVALID_MSGID autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,7f8fc37d854731d6 X-Google-Attributes: gid103376,public X-Google-Thread: 109fba,7f8fc37d854731d6 X-Google-Attributes: gid109fba,public X-Google-Thread: 1108a1,7f8fc37d854731d6 X-Google-Attributes: gid1108a1,public X-Google-Thread: 10461e,7f8fc37d854731d6 X-Google-Attributes: gid10461e,public X-Google-Thread: 114809,7f8fc37d854731d6 X-Google-Attributes: gid114809,public From: Bill Gooch Subject: Re: Interesting but sensitive topic to discuss (HELP: - OOP and CASE tools) Date: 1996/11/11 Message-ID: <32875B03.3729@iconcomp.com>#1/1 X-Deja-AN: 195794613 references: <32813322.41C6@kyebek3.kjist.ac.kr> <55pqr5$136a@grimsel.zurich.ibm.com> <328109CD.6685@concentric.net> <55v177$ufo@grimsel.zurich.ibm.com> <3283BB94.2D82@concentric.net> to: Alan Lovejoy x-rtcode: a48785b5324070846d8759e8 content-type: text/plain; charset=us-ascii organization: Icon Computing mime-version: 1.0 reply-to: bill@iconcomp.com newsgroups: comp.object,comp.lang.c++,comp.lang.ada,comp.lang.smalltalk,comp.ai x-mailer: Mozilla 3.0 (WinNT; I) Date: 1996-11-11T00:00:00+00:00 List-Id: Alan Lovejoy wrote: > > I think you've hit the nail on the head. I do distinguish between "design" and "coding". > > To me, the "design" of a program is a language-independent abstraction. Implementation > inheritance is a coding issue.... I'd like to hear more about how you think design can be done independent of language, and what such a "design" would look like. I can see that the most abstract levels of design can be language-independent, but refinement from this level is an essential aspect (IMO) of doing good design. Such refinement necessarily goes down through layers including language, frame- work, database,... dependencies; in fact, it takes into account *all* requirements, including hardware constraints. If you don't agree that all of this is important in producing good designs, then I have a question: what do you call a program specification, not involving code, which does take these issues into account? I think it is impossible to progress very far from a domain model into design without considering target language, and the other things I've mentioned. A very abstract design, not considering these issues, may be useful some of the time, but the design one actually implements *must* consider them. > Many seem to think that the class hierarchy **is** the design! ... Well, I do not. But there are many levels of design, and it is important to ultimately be specific. > The issues that a design methodology should address with respect to implementation inheritance > would be questions such as the following: > > * Just because two objects have the same behavior may or may not mean that they should > inherit the shared behavior. The methodology should provide the guidance needed to > resolve this issue (is the fact that the behavior is the same simply accidental, or > does it depend upon some reliable invariant? How likely is it that a changed requirement > will necessitate changing the behavior of one of the objects, but not the other?). > > * When should delegation be used instead of inheritance? > > * When should the Strategy pattern be used instead of inheritance? I agree that IWBNI methods could help with these things. I don't know of any method that even comes close, however. This is why design remains largely a black art - not the best situation, but it's the way things are. I'd really like to hear from anyone who can suggest how to address questions such as the ones Alan has raised here in a method(olog)ical or systematic fashion. > However, implementation inheritance should be treated as a refinement of the design, not > as the body and soul of it. >From the last, I gather that in some sense, we are in agreement. But again, what do you call this refinement, if it isn't another (more specific, closer to code) layer of design? -- William D. Gooch bill@iconcomp.com Icon Computing http://www.iconcomp.com Texas liaison for the International Programmers Guild For IPG info, see http://www.ipgnet.com/ipghome.htm