Last week, we had the author of TDD for a Shopping Website LiveProject. Friday at 11am Ranch time, Steven Solomon will be hosting a live TDD session just for us. See for the agenda and registration link
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
  • Campbell Ritchie
  • Paul Clapham
  • Ron McLeod
  • Jeanne Boyarsky
  • Tim Cooke
  • Liutauras Vilda
  • paul wheaton
  • Henry Wong
Saloon Keepers:
  • Tim Moores
  • Tim Holloway
  • Stephan van Hulst
  • Carey Brown
  • Frits Walraven
  • Piet Souris
  • Himai Minh

class diagram questions from UML beginner

Ranch Hand
Posts: 44
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I am a UML beginner. Couple questions about class and component diagram:
1. I have a java application which includes several packages, each has a number of classes.
when I draw class diagram, should I put ALL classes from all packages in one graph, or should I draw a separate class diagrams for each package ? If I draw seperately, how to reflect the interaction among classes that reside in different packages ? Just by using component diagram ?
2. This question has nothing to do with the above one. Sometimes if I have simple scenario, say I have five classes A,B,C,D. All of their "relation" is just class A it uses class B instance to do something, and in class B it uses
class c instances to do someting,etc. that's it. Then in class diagram, should I use arrow connection or line connection to connect class A and class B ?
A->B->C->D or A-B-C-D ?
Ranch Hand
Posts: 782
Python Chrome Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
(1) I'd suggest that you have "several" class diagrams to avoid info-glut. Possible solution:
(a) Have one class diagram per package.
(b) And in the interest of showing the
dependencies b/w packages; create supporting
class diagrams for these only if it enhances
understanding. Avoid trying to achieve completeness by drawing ALL dependencies.
(2) The line with single arrow shows "navigability". If A uses B, the A->B is correct. Associations without arrows imply navigability in both directions (exceptions: when you have aggregation/composition relationships).
[ February 13, 2002: Message edited by: Pho Tek ]
Climb the rope! CLIMB THE ROPE! You too tiny ad:
Free, earth friendly heat - from the CodeRanch trailboss
    Bookmark Topic Watch Topic
  • New Topic