• 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 ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • paul wheaton
  • Paul Clapham
  • Ron McLeod
Sheriffs:
  • Jeanne Boyarsky
  • Liutauras Vilda
Saloon Keepers:
  • Tim Holloway
  • Carey Brown
  • Roland Mueller
  • Piet Souris
Bartenders:

A question about the standard

 
Ranch Hand
Posts: 276
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I've always seen class diagrams with aggregations to other classes elide the associated class from the other classes attribute list. Why is that? Wouldn't it be more clear to always add it?

For example, given a School class and a Department class we might see that depicted like this:



In other words, the department was not shown in the attribute list of School. I always wondered why it was that way as to me, it would be much clearer if it would be added to the attribute list (only have to look in one place to see what the calss has).
 
Ranch Hand
Posts: 1258
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
There's certainly nothing to prevent you from adding a field to the list of attributes for the aggregation. I think the reason most people don't do it is because it would duplicate other information on the diagram--mainly, the actual association itself.
 
reply
    Bookmark Topic Watch Topic
  • New Topic