File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Architect Certification (SCEA/OCMJEA) and the fly likes Class Diagram Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Certification » Architect Certification (SCEA/OCMJEA)
Bookmark "Class Diagram" Watch "Class Diagram" New topic

Class Diagram

John Lincoln
Ranch Hand

Joined: Feb 11, 2003
Posts: 192
Should we capture each and every attribute and method in the class diagram ?

I have close to 60 classes. Can i have one class diagram that shows the relations and expanded one which just shows individual classes withe attributes and operations

The book example given by cade shows only few attributes

Please advise

Rajan Choudhary
Ranch Hand

Joined: Mar 17, 2011
Posts: 196
public methods which will be referred in sequence diagrams are very important and should be shown. privates are optionals, I did show few.
Jeanne Boyarsky
author & internet detective

Joined: May 26, 2003
Posts: 33108

Agreed on showing all methods in your sequence diagrams. You should also show any other important methods. Having two levels of detail is fine to avoid clutter.

[OCA 8 book] [Blog] [JavaRanch FAQ] [How To Ask Questions The Smart Way] [Book Promos]
Other Certs: SCEA Part 1, Part 2 & 3, Core Spring 3, TOGAF part 1 and part 2
Kumar Amit
Ranch Hand

Joined: Aug 13, 2001
Posts: 103
So should the getter and setter in the entities be shown?

Rishi Shehrawat
Ranch Hand

Joined: Aug 11, 2010
Posts: 218

I don't think that we need to show setters/getters.
I agree. Here's the link:
subject: Class Diagram
It's not a secret anymore!