Reputation: 63
I'm taking a course that is going over UML diagrams. I have been assigned to change an ER diagram to a UML diagram. For the most part, I am getting the hang of it, but I have encountered two problems that are confusing to me:
How to represent an attribute of a relationship. Here is an example of what I mean.
I do not know where I would add the "Hours attribute", as in under the Employee or Project class.
Representing two difference relationships between a set of two entities. Sort of like this:
Can I have two associations connecting the classes similar to the image I showed above?
Upvotes: 3
Views: 2143
Reputation: 6529
1) use an association class. It looks like a dashed line connecting a class containing an attribute to an association.
2) you can do these associations exactly the same way in UML. However, I would use one association with verb phrases as the association-end property names.
Upvotes: 2