Re: How much oop is too much oop?



> Example consider a world with 4 shapes: round, square, triangular
and irregular with the last being anything other than the first
three
a.isRound() a.isSquare() a.isTriangular() may need the internal
representation but a.isIrregular() will just return true if all the
others are false.

Virtual functions were invented exactly to make functions like
isWhatever() unnecessary.

.



Relevant Pages

  • Re: How much oop is too much oop?
    ... > Example consider a world with 4 shapes: round, square, triangular ... > and irregular with the last being anything other than the first ... objects questions, rather tell them what to do. ...
    (microsoft.public.vc.language)
  • Re: How much oop is too much oop?
    ... >> Example consider a world with 4 shapes: round, square, triangular ... >> and irregular with the last being anything other than the first ...
    (microsoft.public.vc.language)
  • Re: How much oop is too much oop?
    ... >> Example consider a world with 4 shapes: round, square, triangular ... > Virtual functions were invented exactly to make functions like ... used for this purpose (like a square or regular hexagon, ... Why hamper things by forbidding the question? ...
    (microsoft.public.vc.language)