home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!sun-barr!cs.utexas.edu!swrinde!gatech!hubcap!ncrcae!ncrlnk!psinntp!wrldlnk!usenet
- From: p00058@mail.psi.net (Ronald C. Schultz)
- Newsgroups: comp.object
- Subject: Object-Oriented Methodologies - Class Specifications
- Message-ID: <715276480.1.p00058@mail.psi.net>
- Date: 31 Aug 92 12:56:09 GMT
- Sender: usenet@worldlink.com
- Organization: Berard Software Engineering, Inc.
- Lines: 53
- Nntp-Posting-Host: 127.0.0.1
- X-Mailer: PSILink (3.01)
-
- I am continuing work on completing a methodology comparison of ten OO
- analysis and design methodologies, and I am now in the process of
- comparing methods for issues such as object coupling.
-
- Object Coupling - In order to better support reuse, objects should be as
- decoupled as possible from any specific application, so that they may be
- reused in as many applications as possible. In Rumbaugh's OMT text he
- provides a class specification for a circle on page 290. I quote:
-
- ---- start of quote -------------------------
- Class Description
- Class Name: Circle
- Version: 1.0
- Description: Ellipse whose major and minor axes are equal
- Super Classes: Ellipse
- Features:
- Public Attributes:
- center: Point - location of its center
- radius: Real - its radius
- Public Methods:
- draw (Window) - draws a circle in the window
- intersectLine (Line): Set of Points - finds the
- intersection of a line and a circle, returns set 0-2 points
- area(): Real - calculates area of circle
- perimeter(): Real - calculates circumference of circle
- Private Methods: none
- ---- end of quote --------------------------
-
- This class specification screams of unnecessary object coupling. Why,
- for instance, should a circle need to be aware of the existence of
- lines? or of the existence of windows? To me, this class violates the
- very concept of a circle as defined in any geometry text.
-
- My question - can someone please explain to me why they feel this class
- is legitimate, (or illegitimate for that matter). Why isn't the draw
- operation and intersectLine operation more appropriately assigned to the
- drawing application itself, rather than the circle? Rumbaugh's OMT as
- well as some other OO methods seem to directly oppose long-term reuse of
- the method's analysis and design products. Are others encountering the
- same issues?
-
- Thanx for any assistance.
-
- ------------------------------------------------------------------------------
- Ron Schultz
- Berard Software Engineering, Inc.
- Columbus, Ohio Office Headquarters
- 5634 Claire Court 101 Lakeforest Blvd.
- Dublin, Ohio 43017-2440 Gaithersburg, Md. 20877
- (614) 798-0295 Phone (301) 417-9884 Phone
- (614) 798-0296 FAX (301) 417-0021 FAX
- ron@bse.com info@bse.com
- ------------------------------------------------------------------------------
-