|
Class Association is not always very simple sometimes association has operations and attributes to show such association and to define the features of an association we use association classes.
For example, if I say draw a class diagram for a student taking courses then class diagram would include only two classes “Students” and “Courses” and there will be a simple association between them with many to many multiplicity, means students can take zero or more courses and on other hand courses can have zero or many students. See diagram below:
Now, if I change the system requirements a little and tell you that now the system records assessment of each course the student takes and sends the assessment report to students later on. In this case our association has operation that is to send assessment report and some attributes, lets say grade obtained and total marks. Now we are required to use an association class to show the features of the association we have between students and courses and our class diagram would look something like this:
In the next part i will further explain the concept using a different scenario to strengthen the understanding of this concept so STAY TUNED! Please feel free to use the comments form below if you have any questions or need more explanation on anything.
|
Tags
uml, language, modelling, association, classes,
Popular Searches
linux, php, mysql mysql, mysql, ubuntu, install mysql, gearman, tools, java, source code
more>> |
Comments (write a comment):
if the association class has no other attribute than the composite keys what do I have to put in the attribute box? can I leave it blank?
Posted by: Hestya Patrie on Aug 05, 2011
Yes you can leave it blank
Posted by: Shahbaz on Aug 07, 2011