I'm trying to draw an class diagram for my project management software describing the following. It contains the following classes:
Project
- software projectsProjectManager
- he/she who manage the projectEmployee
- people who are engage in project workand the following relationships/associations:
a project manager may have to manage more than one project, while a project can only be managed by one project manager
a project manager can assign an employee to a project that he/she manages
For the above associations I created this class diagram:
ProjectManager
and Project
)You just add an operation to Project
called assignEmployee
which will add the employee to its list of assigned employees:
It's unclear how an employee can be assigned, whether to just one or multiple projects. Also you will likely need a de-assign operation.
Of course you can also use an association class like suggested by @WolfgangFahl.