AKL012
AKL012

Reputation: 399

Class associations and multiplicity - UML 2.0 - object oriented (Basic)

I am learning UML and I've focused on a Netflix-like project on which to practice on.

I've put together a class association diagram, but have been told that the multiplicities are incorrect. The multiplicities in red represent what I think they should be changed to.

Could someone please offer some clarity of where I have gone wrong?

Please, ask any questions that would help gain a fuller understanding of the diagram in reference to the project.

Thanks in advance.

enter image description here

Upvotes: 0

Views: 389

Answers (1)

qwerty_so
qwerty_so

Reputation: 36333

Movie Catalog - User: The 0..* multiplicity is correct. There can be an arbitrary number of users and not only a single one. That would only work if that Netflix was made for a very single person. And that would be pointless, I guess.

Movie - Membership - Member: This represents an association class for the user to track payments (and access, etc.). So it must be the 1, not 0..*. The stream is sent for that single Membership where it is accounted. An association class has a n-1-1-m relation.

In your model it looks like this:

enter image description here

And from my POV it is:

enter image description here

since the Membership is just used to control access to the movies. It is arguable whether there is only a 1-1 relation and not a (preferable) m-1 relation between Member and Membership.

Upvotes: 0

Related Questions