home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #19 / NN_1992_19.iso / spool / comp / lang / cplus / 12903 < prev    next >
Encoding:
Text File  |  1992-08-25  |  3.0 KB  |  74 lines

  1. Newsgroups: comp.lang.c++
  2. Path: sparky!uunet!mole-end!mat
  3. From: mat@mole-end.matawan.nj.us
  4. Subject: Re: Object What is an OODBMS?
  5. Message-ID: <1992Aug26.010349.3485@mole-end.matawan.nj.us>
  6. Summary: Quick Trick Brick Stack
  7.      (Or the difference between What Is and What It Is Made Of
  8. Organization: :
  9. References: <RCZ5NS@netmbx.netmbx.de> <BEVAN.92Aug12152127@jaguar.cs.man.ac.uk> <JONAS.92Aug22123325@ipcsun5.his.se>
  10. Date: Wed, 26 Aug 1992 01:03:49 GMT
  11. Lines: 61
  12.  
  13. In article <JONAS.92Aug22123325@ipcsun5.his.se>, jonas@ipcsun5.his.se (Jonas Mellin) writes:
  14. > In article <BEVAN.92Aug12152127@jaguar.cs.man.ac.uk> bevan@cs.man.ac.uk (Stephen J Bevan) writes:
  15.  
  16. >    In article <RCZ5NS@netmbx.netmbx.de> jrobie@netmbx.netmbx.de (Jonathan Robie) writes:
  17. >       ... we frequently want to use code or data that ... exist in another
  18. >    class.  ... if we have a ... LinkedList we might ... use this when
  19. >    implementing our stack.  ... we might say that a Stack is a LinkedList
  20. >    which also has the push() and pop() functions.  We can do this
  21. >    directly using ... inheritence:
  22.  
  23. >       class Stack : public LinkedList
  24. >        ...
  25.  
  26. >    Is this generally considered good use/example of inheritance?  I
  27. >    don't think a "Stack is a LinkedList" at all, rather a LinkedList is
  28. >    a possible implementation of a Stack.  I'd therefore use ... a
  29. >    template ...
  30.  
  31. > I too prefer the view of this that Bevan has, but who is to say that
  32. > Stack cannot be a LinkedList?
  33.  
  34. This is the difference between modelling the problem and modelling the
  35. solution.  In general, we _do_ need different tools for modelling
  36.  
  37.     A) Real-world entities and processes
  38.     B) Mathematical entities and processes (mathematical entities
  39.         have no lifetime; math can describe time but it itself
  40.         exists out of time)
  41.     C) Algorithmic entities and the various loosely set-theoretic
  42.         notions that undergird many them
  43.  
  44. And we must be careful not to confuse implementation tricks with the
  45. modelling of the `world' in question.
  46.  
  47.             First, I'll make a quick trick brick stack.
  48.             Then I'll make a quick trick block stack.
  49.             You can make a quick trick chick stack.
  50.             You can make a quick trick clock stack.
  51.                         (_Fox in Socks_, Dr. Seuss)
  52.  
  53. The tricks are great for getting a fast implementation, but a fast
  54. implementation isn't necessarily the one you want for the long term.
  55. They may be good for prototypers, but they may not be so good for the
  56. `real product'.  The real product has to survive many people working on
  57. it, and that probably means that it has to be written with an eye
  58. towards communication.  (Of course, if you are a prototyper, the
  59. prototype _is_ your Real Product ...)
  60.  
  61.             ...
  62.             Clocks on fox tick.  Clocks on Knox tock.
  63.             Six sick bricks tick.  Six sick chicks tock.
  64.             Please sir, I don't like this trick sir.
  65.             My tongue isn't quick or slick sir.
  66.             I get all those ticks and clocks, sir,
  67.                 mixed up with the chicks and tocks sir.
  68.                         (ibid.)
  69. -- 
  70.  (This man's opinions are his own.)
  71.  From mole-end                Mark Terribile
  72.  
  73.  mat@mole-end.matawan.nj.us, Somewhere in Matawan, NJ
  74.