user4897455
user4897455

Reputation: 63

Turning ER diagram to UML: Attributes on Relationships And Managing Two Relationship Sets

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:

  1. How to represent an attribute of a relationship. Here is an example of what I mean.

    example

    I do not know where I would add the "Hours attribute", as in under the Employee or Project class.

  2. Representing two difference relationships between a set of two entities. Sort of like this:

    enter image description here

    Can I have two associations connecting the classes similar to the image I showed above?

Upvotes: 3

Views: 2143

Answers (1)

Jim L.
Jim L.

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

Related Questions